public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "goswin-v-b at web dot de" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug libstdc++/105844] std::lcm(50000, 49999) is UB but accepted in a constexpr due to cast to unsigned Date: Sat, 04 Jun 2022 08:24:31 +0000 [thread overview] Message-ID: <bug-105844-4-7pCJj4fRYd@http.gcc.gnu.org/bugzilla/> (raw) In-Reply-To: <bug-105844-4@http.gcc.gnu.org/bugzilla/> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105844 --- Comment #3 from Goswin von Brederlow <goswin-v-b at web dot de> --- Created attachment 53082 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=53082&action=edit Working patch for detecting UB This will abort if the arguments are too large instead of static_assert, best I could figure out that would work.
next prev parent reply other threads:[~2022-06-04 8:24 UTC|newest] Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top 2022-06-04 1:08 [Bug libstdc++/105844] New: " goswin-v-b at web dot de 2022-06-04 1:11 ` [Bug libstdc++/105844] " goswin-v-b at web dot de 2022-06-04 1:32 ` goswin-v-b at web dot de 2022-06-04 8:24 ` goswin-v-b at web dot de [this message] 2022-06-06 14:22 ` [Bug libstdc++/105844] [10/11/12/13 Regression] " redi at gcc dot gnu.org 2022-06-06 15:19 ` redi at gcc dot gnu.org 2022-06-07 10:07 ` redi at gcc dot gnu.org 2022-06-10 14:24 ` cvs-commit at gcc dot gnu.org 2022-06-28 10:49 ` jakub at gcc dot gnu.org 2022-08-03 13:46 ` [Bug libstdc++/105844] [10/11/12 " cvs-commit at gcc dot gnu.org 2022-08-03 13:49 ` [Bug libstdc++/105844] [10/11 " redi at gcc dot gnu.org 2023-05-03 15:02 ` cvs-commit at gcc dot gnu.org 2023-05-03 15:16 ` cvs-commit at gcc dot gnu.org 2023-05-03 16:34 ` cvs-commit at gcc dot gnu.org 2023-05-03 16:35 ` redi at gcc dot gnu.org 2023-05-03 20:59 ` cvs-commit 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-105844-4-7pCJj4fRYd@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).