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