This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/17000] parse error calling member template function of non-lvalue from within template class member
- From: "giovannibajo at libero dot it" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 12 Aug 2004 13:41:50 -0000
- Subject: [Bug c++/17000] parse error calling member template function of non-lvalue from within template class member
- References: <20040812110815.17000.stefaandr@hotmail.com>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From giovannibajo at libero dot it 2004-08-12 13:41 -------
No, get_a() is a dependent call, since it's a short form for this->get_a().
Consider what happens if you specialize get_a after the definition of func(),
such as:
template <>
void b<float>::get_a() {}
The compiler is right, you have to specify that "func2" is a member template of
whatever get_a() returned, so you need an explicit "template" keyword.
--
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |RESOLVED
Resolution| |INVALID
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17000