Am Fri, 19 Jul 2013 21:43:38 +0200 schrieb Johannes Pfau <[email protected]>:
> Am Fri, 19 Jul 2013 12:38:45 +0200 > schrieb Marco Leise <[email protected]>: > > Would be nice to know if this is working with gdc or ldc. In theory it > should work as we use gcc's exception handling/stack unwinding so it's > probably a dmd bug. That's good to know. Is it possible to port that code into DMD ? How many C libraries do you think are prepared for exceptions ? They might have to clean up memory or system resources. > Slightly off topic, but maybe interesting: > Things can get really nasty if the GCC backend somehow decided > a function is nothrow and you throw from there. Unless GTK uses some > special __nothrow__ attributes that shouldn't happen in C, but I've seen > D code that throws from @nothrow functions and at least on ARM that > crashes... Might be a gdc bug or a problem with the D language > specification. If with @nothrow you mean the nothrow keyword, it has no value for compiler backends, because assert errors can be thrown anyways. But I probably misunderstood you. -- Marco
