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++/58074] [C++11][DR 1333] __is_trivial intrinsic fails for deleted members and for non-trivial copy-c'tors Date: Tue, 18 Jun 2024 20:22:56 +0000 [thread overview] Message-ID: <bug-58074-4-oZHWhYB2Kh@http.gcc.gnu.org/bugzilla/> (raw) In-Reply-To: <bug-58074-4@http.gcc.gnu.org/bugzilla/> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=58074 Marek Polacek <mpolacek at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |mpolacek at gcc dot gnu.org --- Comment #12 from Marek Polacek <mpolacek at gcc dot gnu.org> --- I have a patch for the first assert (via bug 85723), and I think the second assert should also be reversed; that is, I think we want to assert this: ``` struct Trivial { Trivial() = delete; }; struct NonTrivial { NonTrivial() = default; NonTrivial(NonTrivial&) = default; NonTrivial& operator=(NonTrivial&) = default; }; static_assert(!__is_trivial(Trivial), "Ouch"); // #1 static_assert(__is_trivial(NonTrivial), "Ouch"); // #2 ``` The reason for #1 is https://cplusplus.github.io/CWG/issues/1496.html. The reason for #2 is https://cplusplus.github.io/CWG/issues/2171.html (after the https://cplusplus.github.io/CWG/issues/1593.html adjustment).
prev parent reply other threads:[~2024-06-18 20:22 UTC|newest] Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top 2013-08-03 17:58 [Bug c++/58074] New: [C++11] " daniel.kruegler at googlemail dot com 2013-08-03 18:12 ` [Bug c++/58074] " paolo.carlini at oracle dot com 2013-12-09 9:34 ` paolo.carlini at oracle dot com 2015-06-09 20:51 ` richard-gccbugzilla at metafoo dot co.uk 2015-07-09 9:12 ` paolo.carlini at oracle dot com 2015-09-22 15:21 ` [Bug c++/58074] [C++11][DR 1333] " jason at gcc dot gnu.org 2015-09-22 15:22 ` jason at gcc dot gnu.org 2024-06-18 20:22 ` mpolacek 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-58074-4-oZHWhYB2Kh@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).