[e-lang] Reentrancy via Recursion

David-Sarah Hopwood david.hopwood at industrial-designers.co.uk
Thu Feb 26 08:01:43 EST 2009


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.

I think I'd prefer an annotation per object (i.e. 'this object cannot be
reentered'), rather than per call.

DeepFrozen objects can be safely reentered. I think there's a good case
for almost all other objects being non-reentrant. Stateful objects don't
accidentally work correctly when reentered; they have to be designed to
work correctly in that case.

-- 
David-Sarah Hopwood ⚥



More information about the e-lang mailing list