home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / sys / amiga / programmer / 5017 < prev    next >
Encoding:
Text File  |  1996-08-05  |  2.0 KB  |  47 lines

  1. Newsgroups: comp.sys.amiga.programmer
  2. Path: news.nask.org.pl!cyfronet!student!iskra
  3. From: iskra@student.uci.agh.edu.pl (Kamil Iskra)
  4. Subject: Re: GCC warns about OS3.1-protos!(?)
  5. Message-ID: <Dnw363.Bxv@cyf-kr.edu.pl>
  6. Sender: news@cyf-kr.edu.pl (News Administrator)
  7. Nntp-Posting-Host: student.uci.agh.edu.pl
  8. Organization: Academic Computer Centre, CYFRONET
  9. X-Newsreader: TIN [version 1.1 PL8]
  10. References: <Pine.SGI.3.91.960305151659.7781A-100000@RW320B48.rz.fhtw-berlin.de>
  11. Date: Thu, 7 Mar 1996 08:49:15 GMT
  12.  
  13. Robert Rohde (n4297@RW320B48.rz.fhtw-berlin.de) wrote:
  14. > - I compile with:
  15. >    gcc -o RobertsWin RobertsWin.c -Iinclude: -noixemul -s -fbaserel
  16. >   using GCC 2.7.0. 
  17.  
  18. > - While compiling I get following warnings:
  19.  
  20. > In file included from robertswin.c:21: 
  21. > include:clib/dos_protos.h:128: warning: `struct ExAllControl' declared inside
  22. > parameter list
  23. > include:clib/dos_protos.h:128: warning: its scope is only this definition 
  24. > or declaration,
  25. > include:clib/dos_protos.h:128: warning: which is probably not what you want.
  26.  
  27. This is a bug in CBM include files. Prototypes use structures which have
  28. not been defined before. According to ANSI standard, scope of such
  29. structures terminates at the end of prototype, which draws these
  30. prototypes useless - that's why GCC warns you (this is even described in
  31. gcc.guide, in "Bugs" section). 
  32.  
  33. I notified Olaf Barthel about it, so we can hope that new NDUK released by
  34. AT won't have this bug. 
  35.  
  36. If you don't want to see these warnings, include appropriate headers
  37. before prototypes - in your case you should include <dos/exall.h>. Or,
  38. even better, include <proto/dos.h> instead of <clib/dos_protos.h> - this
  39. way all necessary headers will be included automagically and as a bonus
  40. you'll get inline calls :-). 
  41.  
  42. --
  43. / Kamil Iskra - AMIGA 1200, 68030 50MHz, HDD 850 MB, 10 MB RAM \
  44. | iskra@student.uci.agh.edu.pl  kiskra@ernie.icslab.agh.edu.pl |
  45. | http://student.uci.agh.edu.pl/~iskra                         |
  46. \ PGP public key available via Finger or WWW                   /
  47.