This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c++/19030] [4.0 Regression] ice on tree check


------- Additional Comments From reichelt at gcc dot gnu dot org  2004-12-17 19:44 -------
Indeed, this can be demonstrated with the following testcase:

===============================
struct A;

namespace N
{
    struct A;
}

using namespace N;

int A::i;
int A::i;

namespace N
{
    struct C;
    struct C {};
}

class D : N::C {};
===============================

With mainline I get the bogus error message:

PR19030.cc:10: error: 'A' has not been declared
PR19030.cc:11: error: 'A' has not been declared
PR19030.cc:11: error: redefinition of 'int i'
PR19030.cc:10: error: 'int i' previously declared here
PR19030.cc:16: error: conflicting declaration 'struct N::C'
                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
PR19030.cc:15: error: 'struct N::C' has a previous declaration as 'struct N::C'
PR19030.cc:16: internal compiler error: tree check: expected class
'declaration', have 'exceptional' (error_mark) in pushtag, at
cp/name-lookup.c:4672


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19030


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]