🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.std.c
Article #4606

Re: int's and zero

#4606
From: Peter Curran
Date: Wed, 10 Jan 1996 15:14
17 lines
1294 bytes
On 9 Jan 1996 18:09:46 GMT in article <4cub1a$jbl@alterdial.UU.NET>
    rex@aussie.com (rex@aussie.com) wrote:

>There was considerable debate about whether or not integers could be stored 
>as BCD, Grey code, or some such, but in the end, we decided that they had to 
>be stored as binary numbers. And, of course, 2's comp, 1's comp, and signed 
>magnitude all use all-bits-zero for zero. The only thing that could cause a 
>problem is for machines/compilers with signed zeros; I think that negative 
>zero might have some other bit pattern.

I don't think this is the full story.  The *used* bits have to be zero.
However, there has been agreement that the integers can have "holes" (unused
bits), and those bits could be required to be non-zero in some architectures, I
would think. 

--
Peter Curran                               pcurran@inforamp.net
Technical Details
Message-ID: <4d0kd3$d8l@sam.inforamp.net>
Path: arc1-ca.pugleaf.net!inforamp.net!usenet
References: <4cth4e$4q@odin.funcom.no> <4cub1a$jbl@alterdial.UU.NET>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!inforamp.net!usenet
From: pcurran@inforamp.net (Peter Curran)
Newsgroups: comp.std.c
Subject: Re: int's and zero
Date: Wed, 10 Jan 1996 15:14:53 GMT
Organization: PSC Enterprises
Message-ID: <4d0kd3$d8l@sam.inforamp.net>
References: <4cth4e$4q@odin.funcom.no> <4cub1a$jbl@alterdial.UU.NET>
Reply-To: pcurran@inforamp.net
NNTP-Posting-Host: ts13-15.tor.inforamp.net
X-Newsreader: Forte Free Agent 1.0.82