www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2001/06/29/12:50:16

Date: Fri, 29 Jun 2001 19:01:14 +0300
From: "Eli Zaretskii" <eliz AT is DOT elta DOT co DOT il>
Sender: halo1 AT zahav DOT net DOT il
To: schultz AT mathematik DOT tu-muenchen DOT de
Message-Id: <3759-Fri29Jun2001190113+0300-eliz@is.elta.co.il>
X-Mailer: Emacs 20.6 (via feedmail 8.3.emacs20_6 I) and Blat ver 1.8.9
CC: djgpp AT delorie DOT com
In-reply-to: <3B3C9B7B.B0C23FEB@ma.tum.de> (message from Waldemar Schultz on
Fri, 29 Jun 2001 17:15:07 +0200)
Subject: Re: DJGPP reserves wrong int size
References: <9dde68b7 DOT 0106241053 DOT 2a385311 AT posting DOT google DOT com> <200106242138 DOT RAA18013 AT envy DOT delorie DOT com> <3b37e92e DOT 288745911 AT news DOT primus DOT ca> <200106260242 DOT WAA00615 AT envy DOT delorie DOT com> <3b3b4e40 DOT 213415946 AT news DOT primus DOT ca> <6480-Fri29Jun2001102012+0300-eliz AT is DOT elta DOT co DOT il> <3B3C519F DOT C542C834 AT ma DOT tum DOT de> <9628-Fri29Jun2001135845+0300-eliz AT is DOT elta DOT co DOT il> <3B3C9B7B DOT B0C23FEB AT ma DOT tum DOT de>
Reply-To: djgpp AT delorie DOT com
Errors-To: nobody AT delorie DOT com
X-Mailing-List: djgpp AT delorie DOT com
X-Unsubscribes-To: listserv AT delorie DOT com

> Date: Fri, 29 Jun 2001 17:15:07 +0200
> From: Waldemar Schultz <schultz AT mathematik DOT tu-muenchen DOT de>
> 
> verification example ldbl.c:
> #include <stdio.h>
> int main(void)
> {
> long double zz;
> 
>  scanf("%Le",&zz);   
>  scanf("%LE",&zz);   
>  scanf("%lle",&zz); // 8
>  scanf("%llE",&zz); // 9
>  scanf("%Lf",&zz);  
>  scanf("%LF",&zz);  //11
>  scanf("%llf",&zz); //12
>  scanf("%llF",&zz); //13
>  scanf("%Lg",&zz);  
>  scanf("%LG",&zz);  
>  scanf("%llg",&zz); //16
>  scanf("%llG",&zz); //17
> 
>  return 0;
> }
> 
> gcc -W -Wall ldbl.c
> ldbl.c: In function `main':
> ldbl.c:8: warning: use of `q' length character with `e' type character
> ldbl.c:9: warning: use of `q' length character with `E' type character
> ldbl.c:11: warning: unknown conversion type character `F' in format
> ldbl.c:11: warning: too many arguments for format
> ldbl.c:12: warning: use of `q' length character with `f' type character
> ldbl.c:13: warning: unknown conversion type character `F' in format
> ldbl.c:13: warning: too many arguments for format
> ldbl.c:16: warning: use of `q' length character with `g' type character
> ldbl.c:17: warning: use of `q' length character with `G' type character
> 
> >From the doc I would not have expected these warnings.
> Maybe I again have overlooked something .

The documentation describes the library implementation.  The library
accepts all of the combinations you tried and produces expected
results.  The compiler whines (under -W -Wall) because some of these
combination are non-standard, and so the compiler doesn't know about
them.  (Most compilers don't check the format strings, but GCC does.)

- Raw text -


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