Stanislav Malyshev wrote:
finally construct should do that, I think. IMO that's the right solution,
not goto's - and anyway if you allow goto only inside same block, what if
error condition happens inside other block? Are all your functions flat
without control blocks? What if exception happens - are you not going to
clean up then?
Most common solution people choose to emulate exceptions often ends up
being recursive functions, those as well know in many instances result
in crashes.
DR>>which is ugly and already possible anyway).
Using control blocks is no more ugly than using goto's - and thr right way
to do it is using exception handling and finally, IMO.
Most PHP (internal or external) code does not use exceptions, just
saying "use exceptions" may work in Java, but certainly not in PHP.
Ilia
--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php