public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "pinskia at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/58820] lambda multiple inheritance operator() not ambiguous Date: Fri, 27 Aug 2021 20:47:34 +0000 [thread overview] Message-ID: <bug-58820-4-GQv5M7T0O2@http.gcc.gnu.org/bugzilla/> (raw) In-Reply-To: <bug-58820-4@http.gcc.gnu.org/bugzilla/> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=58820 Andrew Pinski <pinskia at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Resolution|--- |INVALID Blocks|54367 | Status|NEW |RESOLVED --- Comment #6 from Andrew Pinski <pinskia at gcc dot gnu.org> --- Unrelated to lambdas really. Here is a C++98 code which shows the same issue with clang: template<class t> struct i { t operator()(t i); }; struct overload_set1 : i<int>, i<double> { overload_set1() {} }; int main(void) { double d1 = 10; overload_set1 tt; tt(d1); } To make the original code work (you need C++17 really): Adding using Fs::operator()...; allows GCC (and ICC) to work. So this is a bug in clang. I don't think we need a testcase as we must likely already have a C++98 one even. Referenced Bugs: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=54367 [Bug 54367] [meta-bug] lambda expressions
prev parent reply other threads:[~2021-08-27 20:47 UTC|newest] Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top 2013-10-21 7:36 [Bug c++/58820] New: " sutambe at yahoo dot com 2013-10-21 12:18 ` [Bug c++/58820] " daniel.kruegler at googlemail dot com 2021-08-27 20:47 ` pinskia 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-58820-4-GQv5M7T0O2@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).