Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 18 Jan 2005 14:29:30 +0100
From:      Erik Trulsson <ertr1013@student.uu.se>
To:        Alexey Dokuchaev <danfe@nsu.ru>
Cc:        freebsd-current@freebsd.org
Subject:   Re: gratuitous gcc warnings: unused function arguments?
Message-ID:  <20050118132930.GA97874@falcon.midgard.homeip.net>
In-Reply-To: <20050118083457.GA57902@regency.nsu.ru>
References:  <Pine.NEB.3.96L.1050116120744.50371A-100000@fledge.watson.org> <20050116144113.GB66854@gothmog.gr> <20050118083457.GA57902@regency.nsu.ru>

next in thread | previous in thread | raw e-mail | index | archive | help
On Tue, Jan 18, 2005 at 02:34:57PM +0600, Alexey Dokuchaev wrote:
> On Sun, Jan 16, 2005 at 04:41:13PM +0200, Giorgos Keramidas wrote:
> > 
> > This allows the main() function to keep being compliant with the ANSI
> > standard that specifies only two valid prototypes for main():
> > 
> > 	int main(void);
> > 	int main(int argc, char *argv[]);
> 
> Hmm, I might sound wrong, but I also recall seeing ``int main(int argc,
> char *argv[], char *envp[]);'' as valid main() prototype as well.

That is not correct according to the ANSI/ISO C standard.
It is a very common extension on Unix systems, but it is not standard C.


-- 
<Insert your favourite quote here.>
Erik Trulsson
ertr1013@student.uu.se



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20050118132930.GA97874>