diff options
author | Volker Reichelt <v.reichelt@netcologne.de> | 2008-04-11 06:55:38 +0000 |
---|---|---|
committer | Volker Reichelt <reichelt@gcc.gnu.org> | 2008-04-11 06:55:38 +0000 |
commit | 21516d643e740854ca7754bfd997539f4bc1183d (patch) | |
tree | 7c7a5c7bc22102fff02d7e4021d1801f36e83a8d /gcc/attribs.c | |
parent | 0598f31b0278920dbcdbe85f9ce5a765cae997f3 (diff) | |
download | gcc-21516d643e740854ca7754bfd997539f4bc1183d.zip gcc-21516d643e740854ca7754bfd997539f4bc1183d.tar.gz gcc-21516d643e740854ca7754bfd997539f4bc1183d.tar.bz2 |
re PR c/35744 (ICE attributes for invalid types)
PR c/35744
* attribs.c (decl_attributes): Return early on errorneous node.
* gcc.dg/attr-error-1.c: New test.
From-SVN: r134193
Diffstat (limited to 'gcc/attribs.c')
-rw-r--r-- | gcc/attribs.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/gcc/attribs.c b/gcc/attribs.c index 767035b..65233de 100644 --- a/gcc/attribs.c +++ b/gcc/attribs.c @@ -225,6 +225,9 @@ decl_attributes (tree *node, tree attributes, int flags) tree a; tree returned_attrs = NULL_TREE; + if (TREE_TYPE (*node) == error_mark_node) + return NULL_TREE; + if (!attributes_initialized) init_attributes (); |