This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/54812] [C++11] Delete expression doesn't respect access of defaulted destructor
- From: "paolo.carlini at oracle dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Fri, 05 Oct 2012 20:53:35 +0000
- Subject: [Bug c++/54812] [C++11] Delete expression doesn't respect access of defaulted destructor
- Auto-submitted: auto-generated
- References: <bug-54812-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54812
Paolo Carlini <paolo.carlini at oracle dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Last reconfirmed| |2012-10-05
Ever Confirmed|0 |1
--- Comment #1 from Paolo Carlini <paolo.carlini at oracle dot com> 2012-10-05 20:53:35 UTC ---
Uhm, this is not trivial to fix. The difference between P1 and P3 is that for
the former from build_delete we call build_dtor_call which eventually also
calls the required perform_or_defer_access_check, whereas for the latter the
function just notices that TYPE_HAS_TRIVIAL_DESTRUCTOR and early returns (via
build_op_delete_call). Arguably, a TYPE_HAS_TRIVIAL_DESTRUCTOR true for a
destructor which actually is private and can't be called sounds a bit strange
but for sure the choice makes sense wrt the rest of the front-end and the
standard... I'll double check soon a few things.
Anyway, here, I only wanted to ask you if this is a show-stopper for your work,
because I don't know how much time it will take.