Skip to content
Snippets Groups Projects
Commit 622d3731 authored by Kaveh R. Ghazi's avatar Kaveh R. Ghazi Committed by Kaveh Ghazi
Browse files

c-parse.in (parsing_iso_function_signature): New variable.

gcc:
	* c-parse.in (parsing_iso_function_signature): New variable.
	(extdef_1): New, copied from...
	(extdef): ... here.  Reset parsing_iso_function_signature.
	(old_style_parm_decls):  Reset parsing_iso_function_signature.
	(old_style_parm_decls_1): New, copied from old_style_parm_decls.
	Warn about ISO C style function definitions.
	(nested_function, notype_nested_function): Reset
	parsing_iso_function_signature.
	(parmlist_2): Set parsing_iso_function_signature.

	* doc/invoke.texi (-Wtraditional): Document new behavior.

gcc/testsuite:
	* gcc.dg/cpp/tr-warn2.c: Use traditional C style function definitions.
	* gcc.dg/wtr-aggr-init-1.c: Likewise.
	* gcc.dg/wtr-conversion-1.c: Likewise.
	* gcc.dg/wtr-escape-1.c: Likewise.
	* gcc.dg/wtr-int-type-1.c: Likewise.
	* gcc.dg/wtr-label-1.c: Likewise.
	* gcc.dg/wtr-static-1.c: Likewise.
	* gcc.dg/wtr-strcat-1.c: Likewise.
	* gcc.dg/wtr-suffix-1.c: Likewise.
	* gcc.dg/wtr-switch-1.c: Likewise.
	* gcc.dg/wtr-unary-plus-1.c: Likewise.
	* gcc.dg/wtr-union-init-1.c: Likewise.
	* gcc.dg/wtr-union-init-2.c: Likewise.
	* gcc.dg/wtr-union-init-3.c: Likewise.

	* gcc.dg/wtr-func-def-1.c: New test.

From-SVN: r55201
parent 9bb46191
No related branches found
No related tags found
No related merge requests found
Showing
with 290 additions and 19 deletions
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment