I am used to programming in Delphi. In that system, a hardware floating point exception, e.g. division by zero, overflow, etc. results in a native Delphi exception being raised. The mechanism is that the hardware exception are not masked and those hardware exceptions are converted, by the Delphi RTL, into native Delphi exceptions.
My app has a plug-in architecture and many of my clients write plug-ins using the MS C++ compiler. When a floating point error occurs in the client's C++ plug-in code this jumps out of the C++ code and into an exception handler in my Delphi code. This makes it difficult for the plug-in author to diagnose where in their code the problem is because, so far as I can tell, they cannot trap these exceptions since they are not C++ exceptions.
Is there any way that I can set some option in the C++ code to make the C++ compiler convert floating point exceptions into C++ exceptions? Or do I have to mask the exceptions in the C++ code and test for errors manually?
And as an aside, how does one go about writing robust scientific and numerical code if the standard C++ tools ignore floating point errors? It seems like a glaring weakness, or am I missing something?