public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/61726] New: Ambiguous overload resolution with inherited op()s
@ 2014-07-06 16:35 kaballo86 at hotmail dot com
  2014-12-14  0:57 ` [Bug c++/61726] " ville.voutilainen at gmail dot com
  2021-12-11  4:15 ` pinskia at gcc dot gnu.org
  0 siblings, 2 replies; 3+ messages in thread
From: kaballo86 at hotmail dot com @ 2014-07-06 16:35 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61726

            Bug ID: 61726
           Summary: Ambiguous overload resolution with inherited op()s
           Product: gcc
           Version: 4.10.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: kaballo86 at hotmail dot com

The following snippet results in an ambiguous overload error:

    struct foo1 { void operator()(int&) const {}; };
    struct foo2 { void operator()(int const&) const {}; };
    struct bar : foo1, foo2 {};

    int main() {
        int i = 0;
        bar{}(i); // error

        int const ci = 0;
        bar{}(ci); // error
    }


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2021-12-11  4:15 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-07-06 16:35 [Bug c++/61726] New: Ambiguous overload resolution with inherited op()s kaballo86 at hotmail dot com
2014-12-14  0:57 ` [Bug c++/61726] " ville.voutilainen at gmail dot com
2021-12-11  4:15 ` pinskia at gcc dot gnu.org

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).