diff options
Diffstat (limited to 'clang/lib/Sema/SemaInit.cpp')
-rw-r--r-- | clang/lib/Sema/SemaInit.cpp | 19 |
1 files changed, 2 insertions, 17 deletions
diff --git a/clang/lib/Sema/SemaInit.cpp b/clang/lib/Sema/SemaInit.cpp index 7c52df5f7c4..1f1e76c9999 100644 --- a/clang/lib/Sema/SemaInit.cpp +++ b/clang/lib/Sema/SemaInit.cpp @@ -3304,31 +3304,16 @@ InitializationSequence::Perform(Sema &S, // Check exception specifications if (S.CheckExceptionSpecCompatibility(CurInitExpr, DestType)) return S.ExprError(); - - // FIXME: We should do this for all types. - if (DestType->isAnyComplexType()) { - CurInit = - S.Owned(CXXBindReferenceExpr::Create(S.Context, - CurInit.takeAs<Expr>(), - /*ExtendsLifetime=*/false, - /*RequiresTemporaryCopy=*/false)); - } break; case SK_BindReferenceToTemporary: + // Reference binding does not have any corresponding ASTs. + // Check exception specifications if (S.CheckExceptionSpecCompatibility(CurInitExpr, DestType)) return S.ExprError(); - // FIXME: We should do this for all types. - if (DestType->isAnyComplexType()) { - CurInit = - S.Owned(CXXBindReferenceExpr::Create(S.Context, - CurInit.takeAs<Expr>(), - /*ExtendsLifetime=*/false, - /*RequiresTemporaryCopy=*/true)); - } break; case SK_UserConversion: { |