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

--- Comment #7 from ensadc at mailnesia dot com ---
(In reply to Zhihao Yuan from comment #6)
> Here is a possibly related case:
> 
> [...]

I think this is a different bug. GCC thinks the implicitly-deleted move
assignment operator `pair<int&>& pair<int&>::operator=(pair<int&>&&)` is a
candidate for the assignment, which causes ambiguity with
`operator=(value_type&&)` (where value_type = pair<int>). But as part of
resolution of CWG 1402, [class.copy.assign] specifies that "A defaulted move
assignment operator that is defined as deleted is ignored by overload
resolution".

Reply via email to