That's not the case here, as this is only directly called by Geany, right?

I was thinking a proxy written in C++ could cause Geany to call it on a subplugin? (but I don't know the details of proxy and geany interaction).

BTW, can really C-linkage stuff throw exceptions? Sure it's somewhat unrelated, but if it's meant to be called by C code it better not throw indeed.

As best I can tell its UB. The extern "C" is defined to control calling convention and name mangling, nothing else. I would doubt the C++ compiler will unilaterally apply noexcept to extern "c" functions since its still ok to call them from C++ as well.

In fact a disaster may occur without even the need to go through C and back to C++. If the stack unwinding moves from C++ to C stack frames, will it see frames without handlers, or will it see some random part of the C frame as specifying an exception handler and do "interesting" things? UB.

Its just very important to prevent all exceptions from exiting C++ into C, one of the rare places where swallowing exceptions is probably acceptable.


You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub, or mute the thread.