diff options
author | Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net> | 2003-05-01 15:02:13 +0000 |
---|---|---|
committer | Kriang Lerdsuwanakij <lerdsuwa@gcc.gnu.org> | 2003-05-01 15:02:13 +0000 |
commit | d0af00afb9247b0719393735c7c49996a8789013 (patch) | |
tree | bf75577d41e389b38f6e0cdfef8bb892b0dfb782 /gcc/cp/decl2.c | |
parent | 85209a3c3b3432c276c4d332e24839b07f0483de (diff) | |
download | gcc-d0af00afb9247b0719393735c7c49996a8789013.zip gcc-d0af00afb9247b0719393735c7c49996a8789013.tar.gz gcc-d0af00afb9247b0719393735c7c49996a8789013.tar.bz2 |
re PR c++/10554 (ICE with illegal using declaration)
PR c++/10554
* decl2.c (do_class_using_decl): Check if operand 0 of SCOPE_REF
is not NULL.
* g++.dg/lookup/using5.C: New test.
From-SVN: r66329
Diffstat (limited to 'gcc/cp/decl2.c')
-rw-r--r-- | gcc/cp/decl2.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/gcc/cp/decl2.c b/gcc/cp/decl2.c index 4f0337d..ec5ff71 100644 --- a/gcc/cp/decl2.c +++ b/gcc/cp/decl2.c @@ -4458,6 +4458,7 @@ do_class_using_decl (tree decl) tree name, value; if (TREE_CODE (decl) != SCOPE_REF + || !TREE_OPERAND (decl, 0) || !TYPE_P (TREE_OPERAND (decl, 0))) { error ("using-declaration for non-member at class scope"); |