From: Taylor R Campbell Date: Mon, 1 Nov 2010 06:56:06 +0000 (+0000) Subject: More fixes to floenv.h. X-Git-Tag: 20101212-Gtk~18 X-Git-Url: https://birchwood-abbey.net/git?a=commitdiff_plain;h=a020e088d26b885222aca754c3814a48ed922e40;p=mit-scheme.git More fixes to floenv.h. --- diff --git a/src/microcode/floenv.h b/src/microcode/floenv.h index 52468db24..40358f137 100644 --- a/src/microcode/floenv.h +++ b/src/microcode/floenv.h @@ -94,6 +94,11 @@ USA. # define FE_INEXACT FP_X_IMP # endif +# ifndef FE_ALL_EXCEPT +# define FE_ALL_EXCEPT \ + (FE_DIVBYZERO | FE_INEXACT | FE_INVALID | FE_OVERFLOW | FE_UNDERFLOW) +# endif + /* FP_X_IOV? */ # ifndef HAVE_FEXCEPT_T @@ -117,7 +122,7 @@ typedef fp_except fexcept_t; /* This isn't right -- it doesn't necessarily actually raise the exception until some floating-point operation is performed. */ # define feraiseexcept(excepts) \ - ((fpsetsticky ((fpgetsticky ()) || (FE_ALL_EXCEPT & (excepts)))), 0) + ((fpsetsticky ((fpgetsticky ()) | (FE_ALL_EXCEPT & (excepts)))), 0) # endif # ifndef HAVE_FEGETEXCEPTFLAG @@ -142,7 +147,7 @@ typedef fp_except fexcept_t; # ifndef HAVE_FEENABLEEXCEPT # define HAVE_FEENABLEEXCEPT # define feenableexcept(excepts) \ - (fpsetmask ((fpgetmask ()) || (FE_ALL_EXCEPT & (excepts)))) + (fpsetmask ((fpgetmask ()) | (FE_ALL_EXCEPT & (excepts)))) # endif # ifndef HAVE_FEDISABLEEXCEPT