the extension to continuation based contification

Stephen Weeks MLton@sourcelight.com
Wed, 22 Nov 2000 13:21:05 -0800 (PST)


I think there's a problem.  Consider the following program.

fun f () = ... h () ... g () ...
fun g () = ... h () ... f () ...
fun h () = ...
 ... K (f ()) ...

All calls are tail calls.  It seems to me that the extended analysis will not be 
able to contify h because it will be called with two different continuations:
"return to f" and "return to g".  On the other hand, with the old analysis, the
set of continuations for f, g, and h would be {K}, and all would be contified.