This is the mail archive of the gcc-cvs@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]

r242667 - in /trunk/gcc: ChangeLog input.c test...


Author: dmalcolm
Date: Mon Nov 21 15:50:38 2016
New Revision: 242667

URL: https://gcc.gnu.org/viewcvs?rev=242667&root=gcc&view=rev
Log:
substring_loc info needs default track-macro-expansion (PR preprocessor/78324)

gcc/ChangeLog:
	PR preprocessor/78324
	* input.c (get_substring_ranges_for_loc): Fail gracefully if
	-ftrack-macro-expansion has a value other than 2.

gcc/testsuite/ChangeLog:
	PR preprocessor/78324
	* gcc.dg/plugin/diagnostic-test-string-literals-1.c
	(test_multitoken_macro): New function.
	* gcc.dg/plugin/diagnostic-test-string-literals-3.c: New test
	case.
	* gcc.dg/plugin/diagnostic-test-string-literals-4.c: New test
	case.
	* gcc.dg/plugin/plugin.exp (plugin_test_list): Add the new test
	cases.
	* gcc.dg/tree-ssa/builtin-sprintf-warn-1.c (test_sprintf_note):
	Move to...
	* gcc.dg/tree-ssa/builtin-sprintf-warn-4.c: ...here.  Drop
	-ftrack-macro-expansion=0.
	(test_sprintf_note): Remove "P" macro.  Add
	dg-begin/end-multiline-output directives.
	(LINE, buffer, ptr): Copy from builtin-sprintf-warn-1.c.


Added:
    trunk/gcc/testsuite/gcc.dg/plugin/diagnostic-test-string-literals-3.c
    trunk/gcc/testsuite/gcc.dg/plugin/diagnostic-test-string-literals-4.c
Modified:
    trunk/gcc/ChangeLog
    trunk/gcc/input.c
    trunk/gcc/testsuite/ChangeLog
    trunk/gcc/testsuite/gcc.dg/plugin/diagnostic-test-string-literals-1.c
    trunk/gcc/testsuite/gcc.dg/plugin/plugin.exp
    trunk/gcc/testsuite/gcc.dg/tree-ssa/builtin-sprintf-warn-1.c
    trunk/gcc/testsuite/gcc.dg/tree-ssa/builtin-sprintf-warn-4.c


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