re PR c++/10749 (triple nested template classes in namespace need to qualify ns)
PR c++/10749 * parser.c (cp_parser_class_head): See through dependent names when parsing a class-head. PR c++/10749 * g++.dg/template/memclass2.C: New test. From-SVN: r68276
This commit is contained in:
parent
a3424f5c1e
commit
66d418e657
@ -1,5 +1,9 @@
|
||||
2003-06-20 Mark Mitchell <mark@codesourcery.com>
|
||||
|
||||
PR c++/10749
|
||||
* parser.c (cp_parser_class_head): See through dependent names
|
||||
when parsing a class-head.
|
||||
|
||||
PR c++/10845
|
||||
* pt.c (try_class_unification): Correct handling of member class
|
||||
templates.
|
||||
|
@ -11634,7 +11634,7 @@ cp_parser_class_head (cp_parser* parser,
|
||||
nested_name_specifier
|
||||
= cp_parser_nested_name_specifier_opt (parser,
|
||||
/*typename_keyword_p=*/false,
|
||||
/*check_dependency_p=*/true,
|
||||
/*check_dependency_p=*/false,
|
||||
/*type_p=*/false);
|
||||
/* If there was a nested-name-specifier, then there *must* be an
|
||||
identifier. */
|
||||
|
@ -1,3 +1,8 @@
|
||||
2003-06-20 Mark Mitchell <mark@codesourcery.com>
|
||||
|
||||
PR c++/10749
|
||||
* g++.dg/template/memclass2.C: New test.
|
||||
|
||||
2003-06-20 Mark Mitchell <mark@codesourcery.com>
|
||||
Eric Botcazou <ebotcazou@libertysurf.fr>
|
||||
|
||||
|
20
gcc/testsuite/g++.dg/template/memclass2.C
Normal file
20
gcc/testsuite/g++.dg/template/memclass2.C
Normal file
@ -0,0 +1,20 @@
|
||||
namespace ns {
|
||||
template<typename T>
|
||||
struct Foo {
|
||||
template<typename U> struct Bar;
|
||||
};
|
||||
|
||||
template<typename T>
|
||||
template<typename U>
|
||||
struct Foo<T>::Bar {
|
||||
template<typename V> struct Baz;
|
||||
};
|
||||
|
||||
template<typename T>
|
||||
template<typename U>
|
||||
template<typename V>
|
||||
struct Foo<T>::Bar<U>::Baz {
|
||||
Foo<T> chokes;
|
||||
ns::Foo<T> works;
|
||||
};
|
||||
}
|
Loading…
Reference in New Issue
Block a user