3 ms·
I can't really comment on the GCC windows stuff: I do software on Linux, and if I'm on windows then I use VC++ (Or a good programming instead e.g. F#/C# usually
by mhh__ 9y ago
I can't really comment on the GCC windows stuff: I do software on Linux, and if I'm on windows then I use VC++ (Or a good programming instead e.g. F#/C# usually). VC++ is modern enough, so the above issue don't even apply very much.
C++ works(TM) with exceptions, AFAIK the vast majority of the ecosystem would use them (Some people e.g. Google and Qt, can't due to existing code). RAII is only really intended to work with exceptions (No return values from constructors, unless! you bodge your own (which you could do, if you were a big organisation))
Edit: Just checked, SEH has been in GCC (64bit) since ~4.8
- jchw 9y agoYep. I mentioned it's not an issue anymore, but back when VC++ was less modern and GCC didn't have SEH support, life was much worse. Now it just has the other aforementioned issues. Obviously, RAII is better with exceptions, at least in theory. It is annoying having to constantly check if the object is valid or not. However, even the standard library does this, so I don't really think it's uncommon - there was definitely some precedent for RAII without exceptions.