aboutsummaryrefslogtreecommitdiff
path: root/clang/lib/Sema/SemaOverload.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'clang/lib/Sema/SemaOverload.cpp')
-rw-r--r--clang/lib/Sema/SemaOverload.cpp11
1 files changed, 4 insertions, 7 deletions
diff --git a/clang/lib/Sema/SemaOverload.cpp b/clang/lib/Sema/SemaOverload.cpp
index 1f25111..37f3511 100644
--- a/clang/lib/Sema/SemaOverload.cpp
+++ b/clang/lib/Sema/SemaOverload.cpp
@@ -2532,15 +2532,12 @@ static bool IsStandardConversion(Sema &S, Expr* From, QualType ToType,
SCS.setToType(2, FromType);
- // If we have not converted the argument type to the parameter type,
- // this is a bad conversion sequence, unless we're resolving an overload in C.
- //
- // Permit conversions from a function without `cfi_unchecked_callee` to a
- // function with `cfi_unchecked_callee`.
- if (CanonFrom == CanonTo || S.AddingCFIUncheckedCallee(CanonFrom, CanonTo))
+ if (CanonFrom == CanonTo)
return true;
- if ((S.getLangOpts().CPlusPlus || !InOverloadResolution))
+ // If we have not converted the argument type to the parameter type,
+ // this is a bad conversion sequence, unless we're resolving an overload in C.
+ if (S.getLangOpts().CPlusPlus || !InOverloadResolution)
return false;
ExprResult ER = ExprResult{From};