[cl-walker-devel] [delico] Persistency with restart-case/handler-case/restart-bind/handler-bind

Thomas Karolski thomas.karolski at googlemail.com
Thu May 13 09:17:48 UTC 2010


While reading your mail I realised that I do not know anything about
the internals of delico or how it is working at all. Which is why I
was hoping for a tutorial to operating the worker, since, well... docs
are really very sparse. I'm already struggling understanding the
different semantics of .def and I see that this is necessary in order
to understand .walker. I'll see how far I can get.

Thanks for the response.

2010/5/12 Attila Lendvai <attila.lendvai at gmail.com>:
> hi!
>
>
>> I was trying to get persistent continuations using hu.dwim.delico,
>> alas it turns out to be troublesome since SBCL internally uses
>> closures to achieve this.
>
>
> the problem is that restarts and condition handlers should be
> reimplemented and CPS transformed by delico because in the current
> setup it does not walk 'cl:signal and friends. and because of that we
> leave the delimited continuation area when they are called from CPS
> transformed code.
>
> it would be nice to have the same condition system in walked and
> non-walked code where conditions could enter and leave the delimited
> continuation area intact.
>
> as of the details of how to implement it... i don't have a worked out idea.
>
> conditions instantiated inside the cc area by a CPS transformed
> condition system implementation could leave the cc area on the top of
> the stack (if it's growing downwards). the custom condition/cc
> instances could contain the native conditions which would be re-thrown
> into the lisp's condition system when leaving the top of the cc area.
>
> as of native conditions thrown while outside the cc area on the bottom
> of the stack... maybe we could install handlers around the native
> calls leaving the cc area, then resignal stuff in the cc condition
> system, then ... ... ... it is getting messy, or i just simply didn't
> spend enough time refining the details.
>
> the point is: either try not to use conditions and/or restarts inside
> walked code, or alternatively work out the details of how to cross the
> cc borders. we are not planning to work on this in the near future.
>
>
>> Since most of the condition system commands are macros, I'd like to
>> know whether it is possible to write custom macros for the walker
>> which try not to depend on closures.
>
>
> you can customize the walker in very flexible ways. e.g. using it to
> compile a lisp dialect to javascript. examples here:
>
> http://dwim.hu/darcsweb/darcsweb.cgi?r=HEAD%20hu.dwim.quasi-quote;a=headblob;f=/source/js/syntax.lisp
>
> --
>  attila
>




More information about the cl-walker-devel mailing list