public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "nok.raven at gmail dot com" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/99795] New: -Wnarrowing/-Woverflow false-negative in constant expression in undeduced context Date: Fri, 26 Mar 2021 16:53:22 +0000 [thread overview] Message-ID: <bug-99795-4@http.gcc.gnu.org/bugzilla/> (raw) https://gcc.gnu.org/bugzilla/show_bug.cgi?id=99795 Bug ID: 99795 Summary: -Wnarrowing/-Woverflow false-negative in constant expression in undeduced context Product: gcc Version: 11.0 Status: UNCONFIRMED Keywords: diagnostic Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: nok.raven at gmail dot com CC: jason at redhat dot com, mpolacek at gcc dot gnu.org Target Milestone: --- template <char N> struct X {}; template <class T> X<sizeof(T)> foo(); int x = sizeof(foo<char[512]>()); template <typename T> struct bar { typedef X<sizeof(T)> t; }; bar<char[512]> y; GCC 4.6-6 had an -Woverflow warning here; since GCC 7 -Wconversion warning was emitted instead, but since bug 99331 is fixed there is no warning at all.
next reply other threads:[~2021-03-26 16:53 UTC|newest] Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top 2021-03-26 16:53 nok.raven at gmail dot com [this message] 2021-03-26 17:44 ` [Bug c++/99795] " mpolacek at gcc dot gnu.org 2021-03-26 17:45 ` [Bug c++/99795] [8/9/10/11 Regression] " mpolacek at gcc dot gnu.org 2021-04-05 21:57 ` jason at gcc dot gnu.org 2021-04-07 17:10 ` jason at gcc dot gnu.org 2021-04-07 17:10 ` jason at gcc dot gnu.org 2021-04-08 13:14 ` rguenth at gcc dot gnu.org 2021-05-14 9:54 ` [Bug c++/99795] [9/10/11/12 " jakub at gcc dot gnu.org 2021-06-01 8:20 ` rguenth at gcc dot gnu.org 2022-05-27 9:44 ` [Bug c++/99795] [10/11/12/13 " rguenth at gcc dot gnu.org 2022-06-28 10:44 ` jakub at gcc dot gnu.org 2023-07-07 10:39 ` [Bug c++/99795] [11/12/13/14 " rguenth at gcc dot gnu.org 2024-03-11 2:54 ` [Bug c++/99795] [11/12 " law 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-99795-4@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).