public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/26278] ambiguous overload candidates list contains duplicates
       [not found] <bug-26278-4@http.gcc.gnu.org/bugzilla/>
@ 2024-02-16 18:06 ` mpolacek at gcc dot gnu.org
  0 siblings, 0 replies; 3+ messages in thread
From: mpolacek at gcc dot gnu.org @ 2024-02-16 18:06 UTC (permalink / raw)
  To: gcc-bugs

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

Marek Polacek <mpolacek at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |mpolacek at gcc dot gnu.org

--- Comment #7 from Marek Polacek <mpolacek at gcc dot gnu.org> ---
Still happens:

$ xg++ -c 26278.C
26278.C: In function ‘int main()’:
26278.C:14:5: error: ambiguous overload for ‘operator==’ (operand types are
‘coEnum<A, X>’ and ‘X’)
   14 |   c == p;
      |   ~ ^~ ~
      |   |    |
      |   |    X
      |   coEnum<A, X>
26278.C:14:5: note: candidate: ‘operator==(X, X)’ (built-in)
   14 |   c == p;
      |   ~~^~~~
26278.C:14:5: note: candidate: ‘operator==(int, int)’ (built-in)
26278.C:14:5: note: candidate: ‘operator==(X, X)’ (built-in)
26278.C:7:8: note: candidate: ‘bool coEnum<e1, e2>::operator==(coEnum<e1, e2>)
const [with e1 = A; e2 = X]’
    7 |   bool operator==(coEnum e) const { return 0; }
      |        ^~~~~~~~

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

* [Bug c++/26278] ambiguous overload candidates list contains duplicates
  2006-02-14 10:36 [Bug c++/26278] New: " igodard at pacbell dot net
  2008-01-26 12:35 ` [Bug c++/26278] ambiguous overload " rguenth at gcc dot gnu dot org
@ 2008-01-29 17:40 ` Ralf dot Wildenhues at gmx dot de
  1 sibling, 0 replies; 3+ messages in thread
From: Ralf dot Wildenhues at gmx dot de @ 2008-01-29 17:40 UTC (permalink / raw)
  To: gcc-bugs

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 668 bytes --]



------- Comment #6 from Ralf dot Wildenhues at gmx dot de  2008-01-29 17:25 -------
Created an attachment (id=15050)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=15050&action=view)
reduced testcase

t.5.ii: In function ‘int main()’:
t.5.ii:14: error: ambiguous overload for ‘operator==’ in ‘c == p’
t.5.ii:14: note: candidates are: operator==(X, X) <built-in>
t.5.ii:14: note:                 operator==(int, int) <built-in>
t.5.ii:14: note:                 operator==(X, X) <built-in>
t.5.ii:7: note:                 bool coEnum<e1, e2>::operator==(coEnum<e1, e2>)
const [with e1 = A, e2 = X]


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=26278


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

* [Bug c++/26278] ambiguous overload candidates list contains duplicates
  2006-02-14 10:36 [Bug c++/26278] New: " igodard at pacbell dot net
@ 2008-01-26 12:35 ` rguenth at gcc dot gnu dot org
  2008-01-29 17:40 ` Ralf dot Wildenhues at gmx dot de
  1 sibling, 0 replies; 3+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2008-01-26 12:35 UTC (permalink / raw)
  To: gcc-bugs



-- 

rguenth at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Severity|normal                      |enhancement
             Status|WAITING                     |NEW
     Ever Confirmed|0                           |1
           Keywords|                            |diagnostic
      Known to fail|                            |4.3.0
   Last reconfirmed|0000-00-00 00:00:00         |2008-01-26 12:25:11
               date|                            |
            Summary|candidates list contains    |ambiguous overload
                   |duplicates                  |candidates list contains
                   |                            |duplicates


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=26278


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

end of thread, other threads:[~2024-02-16 18:06 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <bug-26278-4@http.gcc.gnu.org/bugzilla/>
2024-02-16 18:06 ` [Bug c++/26278] ambiguous overload candidates list contains duplicates mpolacek at gcc dot gnu.org
2006-02-14 10:36 [Bug c++/26278] New: " igodard at pacbell dot net
2008-01-26 12:35 ` [Bug c++/26278] ambiguous overload " rguenth at gcc dot gnu dot org
2008-01-29 17:40 ` Ralf dot Wildenhues at gmx dot de

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