diff options
author | Aldy Hernandez <aldyh@gcc.gnu.org> | 2008-08-21 17:50:01 +0000 |
---|---|---|
committer | Aldy Hernandez <aldyh@gcc.gnu.org> | 2008-08-21 17:50:01 +0000 |
commit | 3d10ed6cbc7248d756077c1e7dc3533257c44a4f (patch) | |
tree | a0c100e51cbbf0a73555687afb760c911a5d2f78 /gcc/c-parser.c | |
parent | eb5712c966473f563c24c8749e1f96d3acb671a2 (diff) | |
download | gcc-3d10ed6cbc7248d756077c1e7dc3533257c44a4f.zip gcc-3d10ed6cbc7248d756077c1e7dc3533257c44a4f.tar.gz gcc-3d10ed6cbc7248d756077c1e7dc3533257c44a4f.tar.bz2 |
c-tree.h (grokfield): New argument.
* c-tree.h (grokfield): New argument.
* c-decl.c (grokfield): Handle new location argument.
* c-parser.c (c_parser_struct_declaration): Pass location to
grokfield.
testsuite/
* gcc.dg/20011008-1.c: Test column.
* gcc.dg/20080820.c: New.
* gcc.dg/fltconst-1.c: Test column.
* gcc.dg/cpp/cpp.exp: Add -fno-show-column.
* gcc.dg/cpp/trad/trad.exp: Same.
* lib/gcc.exp (gcc_target_compile): Remove -fno-show-column.
* lib/gcc-dg.exp (process-message): Handle columns.
From-SVN: r139403
Diffstat (limited to 'gcc/c-parser.c')
-rw-r--r-- | gcc/c-parser.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/gcc/c-parser.c b/gcc/c-parser.c index 7b7d869..e69b0a7 100644 --- a/gcc/c-parser.c +++ b/gcc/c-parser.c @@ -1960,7 +1960,9 @@ c_parser_struct_declaration (c_parser *parser) structs or unions (which is [a] useful and [b] supports MS P-SDK). */ tree attrs = NULL; - ret = grokfield (build_id_declarator (NULL_TREE), specs, + + ret = grokfield (c_parser_peek_token (parser)->location, + build_id_declarator (NULL_TREE), specs, NULL_TREE, &attrs); if (ret) decl_attributes (&ret, attrs, 0); @@ -2003,7 +2005,8 @@ c_parser_struct_declaration (c_parser *parser) } if (c_parser_next_token_is_keyword (parser, RID_ATTRIBUTE)) postfix_attrs = c_parser_attributes (parser); - d = grokfield (declarator, specs, width, &all_prefix_attrs); + d = grokfield (c_parser_peek_token (parser)->location, + declarator, specs, width, &all_prefix_attrs); decl_attributes (&d, chainon (postfix_attrs, all_prefix_attrs), 0); TREE_CHAIN (d) = decls; |