re PR c++/24582 (ICE in decl_jump_unsafe)
2005-11-03 Andrew Pinski <pinskia@physics.uc.edu> PR c++/24582 * g++.dg/init/switch1.C: New test. 2005-11-03 Andrew Pinski <pinskia@physics.uc.edu> PR c++/24582 * decl.c (declare_local_label): Return 0 for variables with error_mark_node as their types. From-SVN: r106434
This commit is contained in:
parent
f9c4ee6d10
commit
b88b7ced9b
4 changed files with 21 additions and 1 deletions
|
@ -1,3 +1,9 @@
|
|||
2005-11-03 Andrew Pinski <pinskia@physics.uc.edu>
|
||||
|
||||
PR c++/24582
|
||||
* decl.c (declare_local_label): Return 0 for variables
|
||||
with error_mark_node as their types.
|
||||
|
||||
2005-11-02 Mark Mitchell <mark@codesourcery.com>
|
||||
|
||||
PR c++/22434
|
||||
|
|
|
@ -2147,7 +2147,8 @@ declare_local_label (tree id)
|
|||
static int
|
||||
decl_jump_unsafe (tree decl)
|
||||
{
|
||||
if (TREE_CODE (decl) != VAR_DECL || TREE_STATIC (decl))
|
||||
if (TREE_CODE (decl) != VAR_DECL || TREE_STATIC (decl)
|
||||
|| TREE_TYPE (decl) == error_mark_node)
|
||||
return 0;
|
||||
|
||||
if (TYPE_NEEDS_CONSTRUCTING (TREE_TYPE (decl))
|
||||
|
|
|
@ -1,3 +1,8 @@
|
|||
2005-11-03 Andrew Pinski <pinskia@physics.uc.edu>
|
||||
|
||||
PR c++/24582
|
||||
* g++.dg/init/switch1.C: New test.
|
||||
|
||||
2005-11-03 Eric Botcazou <ebotcazou@libertysurf.fr>
|
||||
|
||||
* gcc.dg/delay-slot-1.c: New test.
|
||||
|
|
8
gcc/testsuite/g++.dg/init/switch1.C
Normal file
8
gcc/testsuite/g++.dg/init/switch1.C
Normal file
|
@ -0,0 +1,8 @@
|
|||
int f(int c)
|
||||
{
|
||||
switch (c)
|
||||
{
|
||||
case d: /* { dg-error "'d' was not declared" } */
|
||||
int optBzip2 = true;
|
||||
}
|
||||
}
|
Loading…
Add table
Reference in a new issue