Trap floating point exceptions


Some languages and compilers allow trapping floating point exceptions so that, for instance, a computation producing a NaN stops. This is very useful for debugging. Can this be done in julia? There’s which discusses exposing the flags to julia, but maybe there’s a simple way to tell LLVM to raise an exception on FPE?