From 4f5bd82c563d871dc757e128cf76d9f24eaa4203 Mon Sep 17 00:00:00 2001 From: Rick Newton-Rogers Date: Tue, 17 Dec 2024 11:08:42 +0000 Subject: [PATCH] Enable MemberImportVisibility check on all targets (#497) Enable MemberImportVisibility check on all targets. Use a standard string header and footer to bracket the new block for ease of updating in the future with scripts. --- Package.swift | 11 +++++++++++ Sources/NIOSSL/IdentityVerification.swift | 1 + 2 files changed, 12 insertions(+) diff --git a/Package.swift b/Package.swift index 4cb22ac5..2a8682a2 100644 --- a/Package.swift +++ b/Package.swift @@ -144,3 +144,14 @@ let package = Package( ], cxxLanguageStandard: .cxx14 ) + +// --- STANDARD CROSS-REPO SETTINGS DO NOT EDIT --- // +for target in package.targets { + if target.type != .plugin { + var settings = target.swiftSettings ?? [] + // https://github.com/swiftlang/swift-evolution/blob/main/proposals/0444-member-import-visibility.md + settings.append(.enableUpcomingFeature("MemberImportVisibility")) + target.swiftSettings = settings + } +} +// --- END: STANDARD CROSS-REPO SETTINGS DO NOT EDIT --- // diff --git a/Sources/NIOSSL/IdentityVerification.swift b/Sources/NIOSSL/IdentityVerification.swift index dc22233b..8f30a045 100644 --- a/Sources/NIOSSL/IdentityVerification.swift +++ b/Sources/NIOSSL/IdentityVerification.swift @@ -12,6 +12,7 @@ // //===----------------------------------------------------------------------===// +import CNIOLinux import NIOCore #if canImport(Darwin)