Re: Reentrancy via Recursion
David-Sarah Hopwood <david.hopwood-mRVxzIiVagSlV3Ge8JjJtnfLna9zW77MtUK59QYPAWc@public.gmane.org>
| Newsgroups | gmane.comp.lang.e.general |
|---|---|
| Message-ID | <[email protected]> |
Kevin Reid wrote: > On Feb 26, 2009, at 5:46, Toby Murray wrote: > >> Would the addition of another invocation operator (on top of "." and >> "<-") to E that means >> "immediate-call-to-untrusted-object-that-shouldn't-be-able-to- >> recursively-call-me" be fair? Being able to use such an operator >> would enable the programmer not to have to worry about these kinds >> of bugs. > > Having such an operation would expose (by whether it succeeds or > fails) information about the stack, and break determinism. I don't think it exposes information about the stack that isn't already available to the user of such an operation. An object O can simulate this operation (or a similar per-object restriction) by setting a private flag before making the invocation, and then checking whether the flag is set whenever O is entered. Since the simulation is deterministic, so is the proposed operation. -- David-Sarah Hopwood ⚥ _______________________________________________ e-lang mailing list [email protected] http://www.eros-os.org/mailman/listinfo/e-lang