This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/30624] ignores explicit qualification
- From: "pluto at agmk dot net" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 28 Jan 2007 19:41:22 -0000
- Subject: [Bug c++/30624] ignores explicit qualification
- References: <bug-30624-6594@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #1 from pluto at agmk dot net 2007-01-28 19:41 -------
(In reply to comment #0)
> template<typename T> struct foo { T* bar(); };
> struct foo1 : public foo<int>, public foo<bool*> { };
> int main() { foo1 f; f.bar<int>(); }
this is an invalid code.
1). f.bar isn't a function template, so f.bar<type> is wrong.
2). f.bar() is ambiguous and compiler reports correct error.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=30624