+2012-10-12 Marc Glisse <marc.glisse@inria.fr>
+
+ PR c++/53055
+ * c-common.h (enum ref_operator) [RO_ARROW_STAR]: New.
+
2012-10-11 Eric Botcazou <ebotcazou@adacore.com>
* c-ada-spec.c (dump_ada_template): Bail out for template declarations
/* -> */
RO_ARROW,
/* implicit conversion */
- RO_IMPLICIT_CONVERSION
+ RO_IMPLICIT_CONVERSION,
+ /* ->* */
+ RO_ARROW_STAR
} ref_operator;
/* Information about a statement tree. */
+2012-10-12 Marc Glisse <marc.glisse@inria.fr>
+
+ PR c++/53055
+ * call.c (build_new_op_1): Pass RO_ARROW_STAR to cp_build_indirect_ref.
+ * typeck.c (cp_build_indirect_ref): Handle RO_ARROW_STAR.
+
2012-10-11 Jason Merrill <jason@redhat.com>
* cp-tree.h (DECL_THUNKS): NULL_TREE for non-virtual functions.
return cp_build_array_ref (input_location, arg1, arg2, complain);
case MEMBER_REF:
- return build_m_component_ref (cp_build_indirect_ref (arg1, RO_NULL,
+ return build_m_component_ref (cp_build_indirect_ref (arg1, RO_ARROW_STAR,
complain),
arg2, complain);
case RO_IMPLICIT_CONVERSION:
error ("invalid use of implicit conversion on pointer to member");
break;
+ case RO_ARROW_STAR:
+ error ("left hand operand of %<->*%> must be a pointer to class, "
+ "but is a pointer to member of type %qT", type);
+ break;
default:
gcc_unreachable ();
}
+2012-10-12 Marc Glisse <marc.glisse@inria.fr>
+
+ PR c++/53055
+ * g++.dg/pr53055.C: New testcase.
+
2012-10-12 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/52744
--- /dev/null
+// PR c++/53055
+// { dg-do compile }
+
+struct A A :: * p ;
+int i = p ->* p ; // { dg-error "" }