@@ -2040,8 +2040,7 @@ namespace {
20402040 if (Impl.SwiftContext .LangOpts .hasFeature (Feature::LifetimeDependence)) {
20412041 fd->getAttrs ().add (new (Impl.SwiftContext )
20422042 UnsafeNonEscapableResultAttr (/* Implicit=*/ true ));
2043- if (Impl.SwiftContext .LangOpts .hasFeature (Feature::SafeInterop) &&
2044- Impl.SwiftContext .LangOpts .hasFeature (
2043+ if (Impl.SwiftContext .LangOpts .hasFeature (
20452044 Feature::AllowUnsafeAttribute))
20462045 fd->getAttrs ().add (new (Impl.SwiftContext )
20472046 UnsafeAttr (/* Implicit=*/ true ));
@@ -2203,8 +2202,7 @@ namespace {
22032202
22042203 // We have to do this after populating ImportedDecls to avoid importing
22052204 // the same multiple times.
2206- if (Impl.SwiftContext .LangOpts .hasFeature (Feature::SafeInterop) &&
2207- Impl.SwiftContext .LangOpts .hasFeature (
2205+ if (Impl.SwiftContext .LangOpts .hasFeature (
22082206 Feature::AllowUnsafeAttribute)) {
22092207 if (const auto *ctsd =
22102208 dyn_cast<clang::ClassTemplateSpecializationDecl>(decl)) {
@@ -4135,8 +4133,7 @@ namespace {
41354133 LifetimeDependenceInfoRequest{result},
41364134 Impl.SwiftContext .AllocateCopy (lifetimeDependencies));
41374135 }
4138- if (ASTContext.LangOpts .hasFeature (Feature::AllowUnsafeAttribute) &&
4139- ASTContext.LangOpts .hasFeature (Feature::SafeInterop)) {
4136+ if (ASTContext.LangOpts .hasFeature (Feature::AllowUnsafeAttribute)) {
41404137 for (auto [idx, param] : llvm::enumerate (decl->parameters ())) {
41414138 if (swiftParams->get (idx)->getInterfaceType ()->isEscapable ())
41424139 continue ;
@@ -8500,8 +8497,7 @@ static bool importAsUnsafe(ClangImporter::Implementation &impl,
85008497 const clang::NamedDecl *decl,
85018498 const Decl *MappedDecl) {
85028499 auto &context = impl.SwiftContext ;
8503- if (!context.LangOpts .hasFeature (Feature::SafeInterop) ||
8504- !context.LangOpts .hasFeature (Feature::AllowUnsafeAttribute))
8500+ if (!context.LangOpts .hasFeature (Feature::AllowUnsafeAttribute))
85058501 return false ;
85068502
85078503 if (isa<clang::CXXMethodDecl>(decl) &&
0 commit comments