Michel Fortin wrote:
Le 2010-07-30 à 11:29, Sean Kelly a écrit :

Another alternative is deriving all exceptions that shouldn't show a trace by default from an exception with a custom toString that omits this info.

I think we already have one: the OwnerTermianted exception. We could use another 
"normal termination" exception meant to terminate the program. The advantage 
over calling exit(-1) directly is that it'll honor destructors, finally clauses, and 
scope(exit) statements.

Upon catching this exception at main()'s termination, the runtime could print 
its message but omit the stack trace.

This doesn't work. A script could end with virtually any exception.

Andrei

_______________________________________________
phobos mailing list
[email protected]
http://lists.puremagic.com/mailman/listinfo/phobos

Reply via email to