Message ID | 20131104105002.GB30062@redhat.com |
---|---|
State | New |
Headers | show |
On 11/04/2013 05:50 AM, Marek Polacek wrote: > case RO_ARROW: > + case RO_ARROW_STAR: > error_at (loc, > "invalid type argument of %<->%> (have %qT)", > type); I think the diagnostic for RO_ARROW_STAR should say ->*, not just ->. Jason
--- gcc/c-family/c-common.c.mp2 2013-11-04 10:30:15.265951084 +0100 +++ gcc/c-family/c-common.c 2013-11-04 10:47:29.164783425 +0100 @@ -9930,6 +9930,7 @@ invalid_indirection_error (location_t lo type); break; case RO_ARROW: + case RO_ARROW_STAR: error_at (loc, "invalid type argument of %<->%> (have %qT)", type); --- gcc/testsuite/g++.dg/diagnostic/pr58979.C.mp2 2013-11-04 11:09:30.515553664 +0100 +++ gcc/testsuite/g++.dg/diagnostic/pr58979.C 2013-11-04 11:09:26.505538785 +0100 @@ -0,0 +1,4 @@ +// PR c++/58979 +// { dg-do compile } + +int i = 0->*0; // { dg-error "invalid type argument of" }