-
Notifications
You must be signed in to change notification settings - Fork 2.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cross-module exception issue with pre-compiler define _HAS_EXCEPTIONS=0 used in an application #4668
Comments
This is cmake build system problem. VS projects have |
CMake adds /EHsc by default when building on Windows:
Additional define in the application is the root of the problems, not the way Poco is built. |
What can be done in Poco is to verify the value of |
Hi @obiltschnig
I encountered a very subtle issue. It is about
Poco::Exception
inPocoFoundation64.dll
. In Visual Studio 2019/2022 release_shared x64.It is very hard to reproduce. Due to the large amount of code, I can't paste it all here, so I’ve only extracted a small portion.
It took me two days to find the real reason.
It was all caused by
_HAS_EXCEPTIONS=0
in my EXE compile options. This macro will change the class size and implementation of std::exception.I think it's necessary to add some tips in POCO documentation to avoid users wasting unnecessary time on this issue.
See alse: nodejs/node-addon-api#85
The text was updated successfully, but these errors were encountered: