I'm running MinGW (MSYS2) and fairly recently (a couple of months I'd guess) I started having a problem where exception output is not printed on termination.
Minimal example:
#include <SFML/Graphics.hpp>
int main() {
sf::RenderWindow window(sf::VideoMode(1000,1000), "Whatever");
throw std::invalid_argument("BLARGH");
}
I expect this to output and terminate
terminate called after throwing an instance of 'std::invalid_argument'
what(): BLARGH
This works just fine on Linux as well as if I run it via explorer (the "This process has stopped responding" popup opens and the exception output is printed in the terminal in the background). Removing the sf::RenderWindow line also fixes the issue. Normal printing to both stdout and stderr is unaffected.
I cant think of anything in particular that has changed within that timeframe. No MSYS/SFML updates.
I realise this may not be an actual SFML issue (I'm looking into things on MinGW forums as well) but since opening an SFML window manages to consistently trigger it I was hoping anyone here might be able to help me figure out what is causing this issue.