🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.std.c
Article #1354

Re: Questions about NCEG

#1354
From: Paul Eggert
Date: Thu, 31 May 1990 18:00
11 lines
943 bytes
Andrew P. Mullhaupt asks (re `#define infinity (1e300*1e300)'):

	Will this work if the compiler supports IEEE extended format for constants?

In theory, yes.  In practice, no.  I'd prefer

 	#define infinity (1.0/0.0)

which should work on ANSI C + IEEE 754 implementations regardless of format.
However, some compilers balk at `1.0/0.0'.  `1e300*1e300' works on all IEEE 754
implementations that I know of, and also gets through the broken compilers.
Technical Details
Message-ID: <1990May31.180033.18178@twinsun.com>
Path: arc1-ca.pugleaf.net!utzoo!attcan!uunet!aplcen!samsung!sdd.hp.com!zaphod.mps.ohio-state.edu!usc!orion.oac.uci.edu!uci-ics!ucla-cs!twinsun!eggert
References: <73.UUL1.3#5109@pantor.UUCP> <1990May29.193451.6533@twinsun.com> <1008@s6.Morgan.COM>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!attcan!uunet!aplcen!samsung!sdd.hp.com!zaphod.mps.ohio-state.edu!usc!orion.oac.uci.edu!uci-ics!ucla-cs!twinsun!eggert
From: eggert@twinsun.com (Paul Eggert)
Newsgroups: comp.std.c
Subject: Re: Questions about NCEG
Message-ID: <1990May31.180033.18178@twinsun.com>
Date: 31 May 90 18:00:33 GMT
References: <73.UUL1.3#5109@pantor.UUCP> <1990May29.193451.6533@twinsun.com> <1008@s6.Morgan.COM>
Sender: usenet@twinsun.com
Organization: Twin Sun, Inc
Lines: 11