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++/63217] template conversion operator returning const reference not used for conversion in some cases Date: Mon, 09 Aug 2021 23:10:23 +0000 [thread overview] Message-ID: <bug-63217-4-YJgEH6QlSl@http.gcc.gnu.org/bugzilla/> (raw) In-Reply-To: <bug-63217-4@http.gcc.gnu.org/bugzilla/> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63217 Andrew Pinski <pinskia at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- See Also| |https://gcc.gnu.org/bugzill | |a/show_bug.cgi?id=85250 Last reconfirmed|2017-01-08 00:00:00 |2021-8-9 --- Comment #5 from Andrew Pinski <pinskia at gcc dot gnu.org> --- Here is a C++98 version which shows this has always been rejected (well at least since 4.1.2): struct foo { template<class T> operator const T & () { static T t =0; return t;} }; int t = foo();
next prev parent reply other threads:[~2021-08-09 23:10 UTC|newest] Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top 2014-09-10 20:35 [Bug c++/63217] New: " rs2740 at gmail dot com 2014-10-03 12:55 ` [Bug c++/63217] " daniel.kruegler at googlemail dot com 2014-12-13 18:31 ` ville.voutilainen at gmail dot com 2021-08-09 23:10 ` pinskia at gcc dot gnu.org [this message] 2021-12-03 2:11 ` pinskia at gcc dot gnu.org 2021-12-03 2:12 ` pinskia at gcc dot gnu.org 2021-12-03 2:18 ` pinskia at gcc dot gnu.org 2021-12-03 2:21 ` pinskia at gcc dot gnu.org 2021-12-03 2:23 ` pinskia 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-63217-4-YJgEH6QlSl@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).