mirror of
git://gcc.gnu.org/git/gcc.git
synced 2025-01-25 10:04:11 +08:00
* c-parse.in (yylexstring): Use a location_t.
From-SVN: r68645
This commit is contained in:
parent
357734719b
commit
cead95c241
@ -1,5 +1,7 @@
|
|||||||
2003-06-28 Nathan Sidwell <nathan@codesourcery.com>
|
2003-06-28 Nathan Sidwell <nathan@codesourcery.com>
|
||||||
|
|
||||||
|
* c-parse.in (yylexstring): Use a location_t.
|
||||||
|
|
||||||
* diagnostic.h (diagnostic_set_info): Replace file and lineno
|
* diagnostic.h (diagnostic_set_info): Replace file and lineno
|
||||||
parameters with a location_t.
|
parameters with a location_t.
|
||||||
* diagnostic.c (diagnostic_set_info): Replace file and lineno
|
* diagnostic.c (diagnostic_set_info): Replace file and lineno
|
||||||
|
@ -3688,15 +3688,14 @@ yylexstring ()
|
|||||||
varray_type strings;
|
varray_type strings;
|
||||||
|
|
||||||
ifc
|
ifc
|
||||||
static int last_lineno = 0;
|
static location_t last_location;
|
||||||
static const char *last_input_filename = 0;
|
|
||||||
if (warn_traditional && !in_system_header
|
if (warn_traditional && !in_system_header
|
||||||
&& (input_line != last_lineno || !last_input_filename ||
|
&& (input_location.line != last_location.line
|
||||||
strcmp (last_input_filename, input_filename)))
|
|| !last_location.file ||
|
||||||
|
strcmp (last_location.file, input_location.file)))
|
||||||
{
|
{
|
||||||
warning ("traditional C rejects string concatenation");
|
warning ("traditional C rejects string concatenation");
|
||||||
last_lineno = input_line;
|
last_location = input_location;
|
||||||
last_input_filename = input_filename;
|
|
||||||
}
|
}
|
||||||
end ifc
|
end ifc
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user