This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/14566] 'template' disambiguator on base class gives a bad error message
- From: "ron_hylton at hotmail dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 15 Mar 2004 17:58:40 -0000
- Subject: [Bug c++/14566] 'template' disambiguator on base class gives a bad error message
- References: <20040313064317.14566.ron_hylton@hotmail.com>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From ron_hylton at hotmail dot com 2004-03-15 17:58 -------
In the following test case I receive an error message saying the use of the
template disambiguator is required on the base of B::X.
template <class T>
struct A
{
template <class F>
class X
{
};
};
template <class T>
struct B
{
template <class F>
class X : public A<T>::X<F>
{
};
};
--:15: error: non-template `X' used as template
--:15: error: (use `A<T>::template X' to indicate that it is a template)
--:17: error: expected `{' before ';' token
Both Comeau C++ 4.3.3 and Intel Windows Compiler 8.0 accept the template
disambiguator on base classes in all cases I have tried.
--Ron
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=14566