[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: equal tag method [was Re: unicode and locale again]
- From: Edgar Toernig <froese@...>
- Date: Wed, 26 Jun 2002 21:59:44 +0200
Roberto Ierusalimschy wrote:
> > Just define your own rules that are valid on every system; i.e. raise
> > an error on an unordered comparison (that's even a requirement in IEC
> > 60559). To help math-geeks you could provide C-like "non-signaling"
> > methods like isgreater, isgreaterequal, isnan, isnormal, ... in the
> > math-lib.
> How to implement that in ANSI C?
These functions/macros are part of ANSI-C99.
Creating useful ANSI-C89 math semantics my be really difficult. Most
(all?) float stuff seems to be implementation dependent there.
If you want to strictly stick to ANSI_C89 just forget about NaNs, Infs,
and so on and say that working with these values is system/implementation
PS: I don't have C89 here; and only the C99 draft...