I suppose it depends on exactly what equivalence relation you have in
mind on the continuations. My best guess for a fruitful path forward
would be to do something like the "hack" that you suggest below, using
continuation marks to record the information you need until later to
compute the equivalence.

Robby

On Fri, Aug 14, 2015 at 5:40 AM, Klaus Ostermann <klaus...@gmail.com> wrote:
> Is there any way in Racket to use (delimited) continuations to find out 
> whether I'm evaluating an expression in the same evaluation context as before?
>
> Let's assume for a second that Racket had an ordinary call stack, and I could 
> access that call stack as a first-order value. Then I could compare two call 
> stacks and find out whether they denote the same evaluation context or not.
>
> But continuations are of course Racket procedures and eq? always yields #f.
>
> There is literature on defunctionalizing continuations, which would yield a 
> first-order representation of a continuation, but of course I don't want to 
> defunctionalize by hand, hence I wonder whether there is some way to do this 
> with the "batteries" that are included in Racket.
>
> Presumably I could hack something by redefining the application macro, but 
> that's not what I want.
>
> Any ideas?
>
> --
> You received this message because you are subscribed to the Google Groups 
> "Racket Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to racket-users+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to the Google Groups 
"Racket Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to racket-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to