www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1996/04/29/02:43:29

Date: Mon, 29 Apr 1996 09:32:46 +0200 (IST)
From: Eli Zaretskii <eliz AT is DOT elta DOT co DOT il>
To: j DOT aldrich6 AT genie DOT com
Cc: djgpp AT delorie DOT com
Subject: Re: sizeof(int) == 4?!
In-Reply-To: <199604290017.AA082707040@relay1.geis.com>
Message-Id: <Pine.SUN.3.91.960429092941.472L-100000@is>
Mime-Version: 1.0

On Mon, 29 Apr 1996 j DOT aldrich6 AT genie DOT com wrote:

> >The use of long has no effect in DJGPP since int's are "long" (32 bit)
> >by default.
> 
> Actually, printf() and similar commands will moan and groan if you send
> them longs with %d specifiers, or ints with %ld.

No, they won't.  It is only if you invoke gcc with -Wall, it will warn 
you about these, but `printf' will work flawlessly, because in DJGPP (as 
in most 32-bit machines), long and int *are* the same.

Of course, if you want to write portable software, you *will* invoke gcc 
with -Wall and you *will* pay attention to those warnings.

- Raw text -


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