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++/53055] ICE in cp_build_indirect_ref, at cp/typeck.c:2836


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

--- Comment #9 from Manuel LÃpez-IbÃÃez <manu at gcc dot gnu.org> 2012-10-11 18:27:00 UTC ---
(In reply to comment #8)
> Note: this is very old, I barely remember it.
> 
> (In reply to comment #6)
> > Sorry, I think your message is not easily understandable. I think you are
> > trying to say that "the right hand side must be a pointer-to-member",
> 
> No, I think I am saying: hello, this is the left hand side of a ->* operator,
> and you are feeding me a pointer to member, which obviously should be on the
> right hand side.

Ah! I was looking at the testcase here and I got confused.

> test.cc:2:11: error: left hand operand to ->* must be a pointer to class
>       compatible with the right hand operand, but is 'struct  A::*'
> int i = p ->* p ; // { dg-error "" }
>           ^~~
>           .*
> 
> (not sure what that .* is doing there)

Me neither, but clang's text is clearer in my humble opinion. I will be happy
with the text changed to "left-side operand of %<->*%> must a pointer to class
compatible with the right-side operand", and everything the same as your
current patch. Please submit that!


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