emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: (elisp)Numbers


From: Eli Zaretskii
Subject: Re: (elisp)Numbers
Date: Wed, 22 Oct 2003 17:51:10 +0200

> From: Richard Stallman <address@hidden>
> Date: Wed, 22 Oct 2003 05:26:02 -0400
> 
> I have never seen the C9X spec.  What are these changes
> that are relevant to this?

ANSI C89 specifically mandated that math library functions should set
errno when they see abnormal arguments; that means implicitly that the
library cannot generate a SIGFPE, because SIGFPE will (by default)
terminate the program, and thus the program will not have any chance
looking at errno.  In practice, this required that most environments
mask the numerical exceptions, to avoid a SIGFPE.

C9x, AFAIU, requires that a numerical exception be raised, as well as
that errno be set.  So it, in effect, requires a machinery to raise a
``quiet exception'', one that doesn't trigger SIGFPE, at least not by
default.  In other words, the new ANSI standard codifies the numerical
exceptions, which means that library implementors will need to modify
the behavior of library functions to comply.  That is why I expect
some changes in this area as the new standard catches.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]