Commit f7029277 by Jason Merrill Committed by Jason Merrill

* call.c (build_over_call): Handle trivial dtor.

From-SVN: r172809
parent 31603723
2011-04-20 Jason Merrill <jason@redhat.com>
* call.c (build_over_call): Handle trivial dtor.
* search.c (lookup_fnfields_slot): Call complete_type.
PR c++/48594
......
......@@ -6411,7 +6411,11 @@ build_over_call (struct z_candidate *cand, int flags, tsubst_flags_t complain)
return val;
}
/* FIXME handle trivial default constructor and destructor, too. */
else if (DECL_DESTRUCTOR_P (fn)
&& trivial_fn_p (fn)
&& !DECL_DELETED_FN (fn))
return fold_convert (void_type_node, argarray[0]);
/* FIXME handle trivial default constructor, too. */
if (!already_used)
mark_used (fn);
......
2011-04-20 Jason Merrill <jason@redhat.com>
* g++.dg/init/dtor4.C: New.
2011-04-20 Uros Bizjak <ubizjak@gmail.com>
PR target/48678
......
// { dg-final { scan-assembler-not "_ZN1AD2Ev" } }
struct A { };
int main()
{
A a;
a.~A();
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment