This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [C PATCH] Warn about variadic main (PR c/60156)


On 02/12/14 02:51, Marek Polacek wrote:
I figured it might be a good idea to warn about variadic main decl
(well, not in freestanding environment where it's
implementation-defined).

Regtested/bootstrapped on x86_64-linux, ok for 5.0?

2014-02-12  Marek Polacek  <polacek@redhat.com>

	PR c/60156
c-family/
	* c-common.c (check_main_parameter_types): Warn about variadic main.
testsuite/
	* c-c++-common/pr60156.c: New test.
OK. Though in practice I doubt this is going to catch many real bugs. Are people still giving main a stdargs style signature?

jeff


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]