From: Richard Smith Date: Mon, 14 Jul 2014 23:25:30 +0000 (+0000) Subject: Remove dead code. X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=654728df1d045d4e0abc952dca65c0b9ecdc7673;p=clang Remove dead code. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@213013 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/include/clang/Sema/Overload.h b/include/clang/Sema/Overload.h index 7b9f95d635..7c221a2336 100644 --- a/include/clang/Sema/Overload.h +++ b/include/clang/Sema/Overload.h @@ -339,7 +339,6 @@ namespace clang { enum FailureKind { no_conversion, unrelated_class, - suppressed_user, bad_qualifiers, lvalue_ref_to_rvalue, rvalue_ref_to_lvalue diff --git a/lib/Sema/SemaOverload.cpp b/lib/Sema/SemaOverload.cpp index 6f42865c49..03001d89f0 100644 --- a/lib/Sema/SemaOverload.cpp +++ b/lib/Sema/SemaOverload.cpp @@ -1164,17 +1164,6 @@ TryUserDefinedConversion(Sema &S, Expr *From, QualType ToType, ICS.Standard.Second = ICK_Derived_To_Base; } } - - // C++ [over.best.ics]p4: - // However, when considering the argument of a user-defined - // conversion function that is a candidate by 13.3.1.3 when - // invoked for the copying of the temporary in the second step - // of a class copy-initialization, or by 13.3.1.4, 13.3.1.5, or - // 13.3.1.6 in all cases, only standard conversion sequences and - // ellipsis conversion sequences are allowed. - if (SuppressUserConversions && ICS.isUserDefined()) { - ICS.setBad(BadConversionSequence::suppressed_user, From, ToType); - } } else if (UserDefResult == OR_Ambiguous && !SuppressUserConversions) { ICS.setAmbiguous(); ICS.Ambiguous.setFromType(From->getType());