At 11:12 AM +0100 3/27/04, Leopold Toetsch wrote:
Dan Sugalski <[EMAIL PROTECTED]> wrote:

[ mmd functions ]

Another question:

,--[ pdd15 ]------------------------------------------------------
|        While vtable methods may take a continuation, those
|        continuations may not escape the vtable method's
|        execution. This is due to the way that vtable methods are
|        called by the interpreter--once a vtable method is exited
|        any continuation taken within it is no longer valid and
|        may not be used.
`-----------------------------------------------------------------

This seems to indicate that there is no rule that this isn't allowed
generally.

You've got me confused here.


That note in PDD15 is there to try and make it clear that continuations can't cross a C/Parrot boundary. For example, if we have:

Parrot(1) -> C -> Parrot(2)

as a call scheme, such as we'd have with making a vtable function call (since parrot calls into C, and the C code then calls back into parrot) any continuation taken at the Parrot(2) level can't escape back and be invoked in code at the Parrot(1) level. To do so we'd need to save the system stack, which is problematic.
--
Dan


--------------------------------------"it's like this"-------------------
Dan Sugalski                          even samurai
[EMAIL PROTECTED]                         have teddy bears and even
                                      teddy bears get drunk

Reply via email to