Hi Benoit, when programming a component in C/C++, one can use the error hook to execute a function when the interpreter is about to abort because of an error.
In Gambas itself, we only have the local Catch blocks to execute code in case of error in this or any context above in the stack. However, there is no global error handling routine like the above error hook available for Gambas programs. It would be handy if the program ultimately has to tidy up some of its business before it is killed. A rather dull example would be the one we initially intended: a Circular from gb.data might be good to store program logs because it has a fixed size. In case of an unexpected program error we would like to dump this Circular. Easy when programming a component in C/C++ but impossible in Gambas. AFAIK! Thoughts? Regards, Tobi ------------------------------------------------------------------------------ Try New Relic Now & We'll Send You this Cool Shirt New Relic is the only SaaS-based application performance monitoring service that delivers powerful full stack analytics. Optimize and monitor your browser, app, & servers with just a few lines of code. Try New Relic and get this awesome Nerd Life shirt! http://p.sf.net/sfu/newrelic_d2d_may _______________________________________________ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user