This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c++/13113] [3.4 regression] Nice warning about &(X::m) lost


------- Additional Comments From gdr at integrable-solutions dot net  2003-11-20 03:10 -------
Subject: Re:  New: [3.4 regression] Nice warning about &(X::m) lost

"bangerth at dealii dot org" <gcc-bugzilla@gcc.gnu.org> writes:

| Sometime in the 3.2 series, a nice warning was introduced for
| code like this:
| --------------------
| struct A {
|     int f();
| };
| 
| int (A::*p)() = &(A::f);
| ---------------------
| 
| g/x> /home/bangerth/bin/gcc-3.2.3/bin/c++ -c x.cc
| x.cc:5: parenthesis around 'A::f()' cannot be used to form a
|    pointer-to-member-function
| 
| This got lost with the new parser, which now says

:-(  That warning was part of the job of resolve_offset_xxx -- which
used to ICE on such code.  
I wish the cp/error.c display 'A::f' instead of the silly 'A::f()',
but it is something that seemseasier to do with the new
pretty-printer.

-- Gaby


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13113


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]