public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "cvs-commit at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c++/108243] [11/12 Regression] Missed optimization for static const std::string_view(const char*)
Date: Wed, 13 Dec 2023 16:48:13 +0000	[thread overview]
Message-ID: <bug-108243-4-Lg0nJ7elk1@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-108243-4@http.gcc.gnu.org/bugzilla/>

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108243

--- Comment #16 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The trunk branch has been updated by Jason Merrill <jason@gcc.gnu.org>:

https://gcc.gnu.org/g:958940eb3511e341e57606f5a2f5399bc89533cb

commit r14-6506-g958940eb3511e341e57606f5a2f5399bc89533cb
Author: Jason Merrill <jason@redhat.com>
Date:   Tue Dec 12 22:53:10 2023 -0500

    c++: constant direct-initialization [PR108243]

    When testing the proposed patch for PR71093 I noticed that it changed the
    diagnostic for consteval-prop6.C.  I then noticed that the diagnostic
wasn't
    very helpful either way; it was complaining about modification of the 'x'
    variable, but it's not a problem to initialize a local variable with a
    consteval constructor as long as the value is actually constant, we want to
    know why the value isn't constant.  And then it turned out that this also
    fixed a missed-optimization bug in the testsuite.

            PR c++/108243

    gcc/cp/ChangeLog:

            * constexpr.cc (cxx_eval_outermost_constant_expr): Turn
            a constructor CALL_EXPR into a TARGET_EXPR.

    gcc/testsuite/ChangeLog:

            * g++.dg/cpp2a/consteval-prop6.C: Adjust diagnostic.
            * g++.dg/opt/is_constant_evaluated3.C: Remove xfails.

      parent reply	other threads:[~2023-12-13 16:48 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-12-28 16:31 [Bug c++/108243] New: " erosenberger at kinetica dot com
2023-01-04 11:42 ` [Bug c++/108243] " redi at gcc dot gnu.org
2023-01-04 13:05 ` redi at gcc dot gnu.org
2023-01-04 13:15 ` redi at gcc dot gnu.org
2023-01-04 13:20 ` [Bug c++/108243] [10/11/12/13 Regression] " redi at gcc dot gnu.org
2023-01-04 13:21 ` redi at gcc dot gnu.org
2023-01-04 16:47 ` ppalka at gcc dot gnu.org
2023-01-04 17:22 ` jakub at gcc dot gnu.org
2023-01-09 14:05 ` rguenth at gcc dot gnu.org
2023-01-27 19:13 ` ppalka at gcc dot gnu.org
2023-02-17 20:21 ` cvs-commit at gcc dot gnu.org
2023-02-20  5:23 ` de34 at live dot cn
2023-02-20 18:33 ` ppalka at gcc dot gnu.org
2023-02-21 13:38 ` rguenth at gcc dot gnu.org
2023-02-21 14:09 ` ppalka at gcc dot gnu.org
2023-03-02 19:05 ` cvs-commit at gcc dot gnu.org
2023-03-02 19:05 ` cvs-commit at gcc dot gnu.org
2023-03-02 19:51 ` [Bug c++/108243] [10/11/12 " ppalka at gcc dot gnu.org
2023-07-07 10:44 ` [Bug c++/108243] [11/12 " rguenth at gcc dot gnu.org
2023-12-13 16:48 ` cvs-commit at gcc dot gnu.org [this message]

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-108243-4-Lg0nJ7elk1@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: link
Be 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).