delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1998/01/20/22:45:40

From: "John M. Aldrich" <fighteer AT cs DOT com>
Newsgroups: comp.os.msdos.djgpp
Subject: Re: 64 bit integers ??!?
Date: Tue, 20 Jan 1998 22:43:28 -0500
Organization: Two pounds of chaos and a pinch of salt.
Lines: 27
Message-ID: <34C56EE0.1F9D@cs.com>
References: <C1256592 DOT 002E78CA DOT 00 AT vega DOT ads DOT it>
NNTP-Posting-Host: ppp203.cs.com
Mime-Version: 1.0
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp

G DOT DegliEsposti AT ads DOT it wrote:
> 
> >Strange, since an int is 32bit, I wonder 64bit integer are not declared at
> >long int instead.
> 
> That's because the ANSI standard says explicitly that long int is 32 bit
> long

That's incorrect.  ANSI states that:

  short >= 16 bits
  long  >= 32 bits
  short <= int <= long

That's the limit of the ANSI restrictions.  However, most
implementations preserve longs as 32 bits, simply because most
architectures _are_ 32-bit, and most code assumes long to be 32 bits. 
64-bit integer implementation is spotty at best; perhaps when 64-bit
systems become more prevalent we'll see a change.

-- 
---------------------------------------------------------------------
|      John M. Aldrich       |"Men rarely (if ever) manage to dream |
|       aka Fighteer I       |up a god superior to themselves. Most |
|   mailto:fighteer AT cs DOT com   |gods have the manners and morals of a |
| http://www.cs.com/fighteer |spoiled child."    - Lazarus Long     |
---------------------------------------------------------------------

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019