This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: prototypes for functions with no arguments
- From: Neil Booth <neil at daikokuya dot co dot uk>
- To: Matt Kraai <kraai at alumni dot cmu dot edu>
- Cc: gcc at gcc dot gnu dot org
- Date: Mon, 1 Jul 2002 20:42:28 +0100
- Subject: Re: prototypes for functions with no arguments
- References: <20020701185441.GE570@catalonia>
Matt Kraai wrote:-
> Howdy,
>
> I'm not certain, but it appears that in K+R compatible parts of
> the compiler, declarations of functions with no arguments should
> use `PARAMS ((void))', and definitions should use `()'. Using
> `(void)' in either circumstance is not correct.
>
> Is this correct? Should it be documented in README.Portability,
> or is the current documentation sufficient?
Yes it's correct. Feel free to update the document.
Neil.