diff options
author | dodji <dodji@138bc75d-0d04-0410-961f-82ee72b054a4> | 2009-01-15 13:01:36 +0000 |
---|---|---|
committer | dodji <dodji@138bc75d-0d04-0410-961f-82ee72b054a4> | 2009-01-15 13:01:36 +0000 |
commit | c64e181a62ecb952079179ab2753bf042e433eb4 (patch) | |
tree | 8ca33664ec27d51df5afd32841c045cfe53bb37e /gcc/cp/name-lookup.c | |
parent | eb940a48785ef5ef01194b20c806c4e80d572bfa (diff) | |
download | gcc-c64e181a62ecb952079179ab2753bf042e433eb4.tar.gz |
gcc/cp/ChangeLog:
2009-01-13 Dodji Seketeli <dodji@redhat.com>
PR c++/38636
* name-lookup.c (pushtag): Don't create members to types that are not
being created.
gcc/testsuite/ChangeLog:
2009-01-13 Dodji Seketeli <dodji@redhat.com>
PR c++/38636
* g++.dg/parse/crash50.C: New test.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@143392 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/cp/name-lookup.c')
-rw-r--r-- | gcc/cp/name-lookup.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/gcc/cp/name-lookup.c b/gcc/cp/name-lookup.c index 6dc244fccb8..f8d0204f099 100644 --- a/gcc/cp/name-lookup.c +++ b/gcc/cp/name-lookup.c @@ -5109,6 +5109,9 @@ pushtag (tree name, tree type, tag_scope scope) if (b->kind == sk_class) { + if (!TYPE_BEING_DEFINED (current_class_type)) + POP_TIMEVAR_AND_RETURN (TV_NAME_LOOKUP, error_mark_node); + if (!PROCESSING_REAL_TEMPLATE_DECL_P ()) /* Put this TYPE_DECL on the TYPE_FIELDS list for the class. But if it's a member template class, we want |