This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/11814] Code with missing "template" keyword wrongly accepted
- From: "redi at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 25 Mar 2005 20:38:29 -0000
- Subject: [Bug c++/11814] Code with missing "template" keyword wrongly accepted
- References: <20030805230939.11814.reichelt@gcc.gnu.org>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From redi at gcc dot gnu dot org 2005-03-25 20:38 -------
This can be simplified to:
template <class T> void f()
{
T t;
t.f<>(0); //should be t.template f<>(0);
}
If either 'f' is renamed g++ correctly reports an error.
Comeau's online compiler behaves the same.
--
What |Removed |Added
----------------------------------------------------------------------------
CC| |redi at gcc dot gnu dot org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11814