2017-08-10 Jason Merrill <jason@redhat.com>
+ PR c++/81359 - Unparsed NSDMI error from SFINAE context.
+ * method.c (synthesized_method_walk): Don't diagnose lack of
+ operator delete.
+
PR c++/80452 - Core 1579, implicit move semantics on return/throw
* cp-tree.h (LOOKUP_PREFER_RVALUE): Now means that we've already
tentatively changed the lvalue to an rvalue.
if (check_vdtor && type_has_virtual_destructor (BINFO_TYPE (base_binfo)))
{
- fn = locate_fn_flags (ctype, cp_operator_id (DELETE_EXPR),
- ptr_type_node, flags, complain);
/* Unlike for base ctor/op=/dtor, for operator delete it's fine
to have a null fn (no class-specific op delete). */
- if (fn && fn == error_mark_node && deleted_p)
- *deleted_p = true;
+ fn = locate_fn_flags (ctype, cp_operator_id (DELETE_EXPR),
+ ptr_type_node, flags, tf_none);
+ if (fn && fn == error_mark_node)
+ {
+ if (complain & tf_error)
+ locate_fn_flags (ctype, cp_operator_id (DELETE_EXPR),
+ ptr_type_node, flags, complain);
+ if (deleted_p)
+ *deleted_p = true;
+ }
check_vdtor = false;
}
}