[cfe-dev] of -fno-exceptions, ObjC++, __EXCEPTIONS, Mac vs. Linux ... and Qt

René J.V. Bertin via cfe-dev cfe-dev at lists.llvm.org
Fri May 26 10:12:23 PDT 2017


On Friday May 26 2017 09:27:21 Reid Kleckner wrote:
>So far as I can tell, __EXCEPTIONS behaves as documented: it is defined if

Yes, but only on Mac, at least according to the documentation I linked to. But that's 4 versions old by now, things could have changed in the meantime.

>Clang will emit exceptional destructor cleanups. How it is defined on
>Darwin vs. Linux vs. Obj-C++ is all based on crazy different platform
>defaults that I can't untangle.

That too should be documented...

>It sounds like Obj-C++ on Mac enables Obj-C
>exceptions by default, which means we keep around C++ destructor cleanups,
>so __EXCEPTIONS is defined.

I'm pretty sure that when I tried on Linux (targetting Linux) I also saw -fobjc_exceptions in the commandline arguments.

R.



More information about the cfe-dev mailing list