Custom default exception handler?

Nick Sabalausky SeeWebsiteToContactMe at semitwist.com
Tue Feb 11 17:02:31 PST 2014


On 2/11/2014 10:00 AM, Adam D. Ruppe wrote:
> So this would work too:
>
> int handleError(void delegate() dg) {
>          try dg();
>          catch(Throwable t) return 1;
>          return 0;
> }
>
> int main() {
>          return handleError({
>
>          });
> }
>

Oh yea, good point. That's not bad at all;



More information about the Digitalmars-d-learn mailing list