From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 3035 invoked by alias); 26 Jan 2014 19:29:31 -0000 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org Received: (qmail 2988 invoked by uid 48); 26 Jan 2014 19:29:27 -0000 From: "richard-gccbugzilla at metafoo dot co.uk" To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/59389] [C++11] bogus error:=?UTF-8?Q?=20call=20of=20overloaded=20=E2=80=98Foo?=()=?UTF-8?Q?=E2=80=99=20is=20ambiguous?= Date: Sun, 26 Jan 2014 19:29:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: c++ X-Bugzilla-Version: unknown X-Bugzilla-Keywords: rejects-valid X-Bugzilla-Severity: normal X-Bugzilla-Who: richard-gccbugzilla at metafoo dot co.uk X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-SW-Source: 2014-01/txt/msg02713.txt.bz2 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=59389 --- Comment #5 from Richard Smith --- Under [over.best.ics]p4, I think both the original example in comment#0 and the example in comment#2 are valid (so GCC is incorrect to reject both and Clang is incorrect to reject #2). The user-defined conversion from {"abc", {"aaa"}} to Foo is not considered when forming the implicit conversion sequence for the first parameter of Foo's copy or move constructor, so neither of those is viable in either case. But see also core issue 1758.