This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/21801] New: Accepts invalid for const member pointer functions
- From: "pinskia at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 28 May 2005 17:54:09 -0000
- Subject: [Bug c++/21801] New: Accepts invalid for const member pointer functions
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
Looking at PR 21799, I noticed that we accept the code if we remove the second template function, like
so:
template <class T> void f (T &, void (T::*)() );
struct X {
void g() const;
};
const X *x;
int main () {
f (*x, &X::g);
}
--
Summary: Accepts invalid for const member pointer functions
Product: gcc
Version: 4.0.0
Status: UNCONFIRMED
Keywords: accepts-invalid
Severity: normal
Priority: P2
Component: c++
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: pinskia at gcc dot gnu dot org
CC: gcc-bugs at gcc dot gnu dot org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21801