public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "mpolacek at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/105529] [13 Regression] cxx_eval_store_expression on arm because of ctor returning this since r13-160-g967cdbe6629653 Date: Mon, 09 May 2022 16:31:52 +0000 [thread overview] Message-ID: <bug-105529-4-ObYl1uDUlf@http.gcc.gnu.org/bugzilla/> (raw) In-Reply-To: <bug-105529-4@http.gcc.gnu.org/bugzilla/> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105529 Marek Polacek <mpolacek at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |mpolacek at gcc dot gnu.org --- Comment #2 from Marek Polacek <mpolacek at gcc dot gnu.org> --- We're in cxx_eval_store_expression, evaluating <retval> = this, this is while evaluating a CALL_EXPR allocator::~allocator (&D.4529). We're on ARM, so cdtors return this. init is evaluated to &D.4529 [allocator *], object is <retval> [void *]. Their types aren't the same so we go to if (empty_base || !(same_type_ignoring_top_level_qualifiers_p (TREE_TYPE (init), type))) { /* For initialization of an empty base, the original target will be *(base*)this, evaluation of which resolves to the object argument, which has the derived type rather than the base type. In this situation, just evaluate the initializer and return, since there's no actual data to store, and we didn't build a CONSTRUCTOR. */ empty_base = true; gcc_assert (is_empty_class (TREE_TYPE (init))); and is_empty_class will always say false for a pointer type -> ICE. I don't think we should have gotten into this branch.
next prev parent reply other threads:[~2022-05-09 16:31 UTC|newest] Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top 2022-05-09 7:47 [Bug c++/105529] New: [13 Regression] cxx_eval_store_expression, at cp/constexpr.cc:5928 " marxin at gcc dot gnu.org 2022-05-09 7:47 ` [Bug c++/105529] " marxin at gcc dot gnu.org 2022-05-09 8:15 ` [Bug c++/105529] [13 Regression] cxx_eval_store_expression on arm because of ctor returning this " rguenth at gcc dot gnu.org 2022-05-09 8:48 ` dcb314 at hotmail dot com 2022-05-09 16:31 ` mpolacek at gcc dot gnu.org [this message] 2022-05-09 17:11 ` mpolacek at gcc dot gnu.org 2022-05-10 5:06 ` cvs-commit at gcc dot gnu.org 2022-05-10 5:06 ` jason at gcc dot gnu.org
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=bug-105529-4-ObYl1uDUlf@http.gcc.gnu.org/bugzilla/ \ --to=gcc-bugzilla@gcc.gnu.org \ --cc=gcc-bugs@gcc.gnu.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).