From: Taylor R Campbell Date: Sat, 15 Dec 2018 21:44:39 +0000 (+0000) Subject: Exclude exceptions not in FE_ALL_EXCEPT. X-Git-Tag: mit-scheme-pucked-10.1.9~3^2~35^2~6 X-Git-Url: https://birchwood-abbey.net/git?a=commitdiff_plain;h=89bda900291968b4f6de5570d5dae31e9edee865;p=mit-scheme.git Exclude exceptions not in FE_ALL_EXCEPT. Some buggy libms omit some FE_* from FE_ALL_EXCEPT, apparently, oops. When they cease to be relevant to me we can remove this. --- diff --git a/src/microcode/floenv.c b/src/microcode/floenv.c index 8d29ad106..c9e08102e 100644 --- a/src/microcode/floenv.c +++ b/src/microcode/floenv.c @@ -360,35 +360,35 @@ arg_float_exceptions_to_trap (int n) DEFINE_PRIMITIVE ("FLOAT-INVALID-OPERATION-EXCEPTION", Prim_float_invalid_operation_exception, 0, 0, 0) #ifdef FE_INVALID - FLOAT_EXCEPTIONS_PRIMITIVE (FE_INVALID) + FLOAT_EXCEPTIONS_PRIMITIVE (FE_INVALID & FE_ALL_EXCEPT) #else UNIMPLEMENTED_FLOAT_EXCEPTIONS_PRIMITIVE () #endif DEFINE_PRIMITIVE ("FLOAT-DIVIDE-BY-ZERO-EXCEPTION", Prim_float_divide_by_zero_exception, 0, 0, 0) #ifdef FE_DIVBYZERO - FLOAT_EXCEPTIONS_PRIMITIVE (FE_DIVBYZERO) + FLOAT_EXCEPTIONS_PRIMITIVE (FE_DIVBYZERO & FE_ALL_EXCEPT) #else UNIMPLEMENTED_FLOAT_EXCEPTIONS_PRIMITIVE () #endif DEFINE_PRIMITIVE ("FLOAT-OVERFLOW-EXCEPTION", Prim_float_overflow_exception, 0, 0, 0) #ifdef FE_OVERFLOW - FLOAT_EXCEPTIONS_PRIMITIVE (FE_OVERFLOW) + FLOAT_EXCEPTIONS_PRIMITIVE (FE_OVERFLOW & FE_ALL_EXCEPT) #else UNIMPLEMENTED_FLOAT_EXCEPTIONS_PRIMITIVE () #endif DEFINE_PRIMITIVE ("FLOAT-UNDERFLOW-EXCEPTION", Prim_float_underflow_exception, 0, 0, 0) #ifdef FE_UNDERFLOW - FLOAT_EXCEPTIONS_PRIMITIVE (FE_UNDERFLOW) + FLOAT_EXCEPTIONS_PRIMITIVE (FE_UNDERFLOW & FE_ALL_EXCEPT) #else UNIMPLEMENTED_FLOAT_EXCEPTIONS_PRIMITIVE () #endif DEFINE_PRIMITIVE ("FLOAT-INEXACT-RESULT-EXCEPTION", Prim_float_inexact_result_exception, 0, 0, 0) #ifdef FE_INEXACT - FLOAT_EXCEPTIONS_PRIMITIVE (FE_INEXACT) + FLOAT_EXCEPTIONS_PRIMITIVE (FE_INEXACT & FE_ALL_EXCEPT) #else UNIMPLEMENTED_FLOAT_EXCEPTIONS_PRIMITIVE () #endif @@ -397,7 +397,7 @@ DEFINE_PRIMITIVE ("FLOAT-INEXACT-RESULT-EXCEPTION", Prim_float_inexact_result_ex DEFINE_PRIMITIVE ("FLOAT-SUBNORMAL-OPERAND-EXCEPTION", Prim_float_subnormal_operand_exception, 0, 0, 0) #ifdef FE_DENORMAL - FLOAT_EXCEPTIONS_PRIMITIVE (FE_DENORMAL) + FLOAT_EXCEPTIONS_PRIMITIVE (FE_DENORMAL & FE_ALL_EXCEPT) #else UNIMPLEMENTED_FLOAT_EXCEPTIONS_PRIMITIVE () #endif