Skip to content

Commit 4adaaef

Browse files
committed
Only apply standard swift settings on valid targets
1 parent 6682b9c commit 4adaaef

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

Package.swift

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,11 +59,16 @@ for target in package.targets {
5959

6060
// --- STANDARD CROSS-REPO SETTINGS DO NOT EDIT --- //
6161
for target in package.targets {
62-
if target.type != .plugin {
62+
switch target.type {
63+
case .regular, .test, .executable:
6364
var settings = target.swiftSettings ?? []
6465
// https://github.com/swiftlang/swift-evolution/blob/main/proposals/0444-member-import-visibility.md
6566
settings.append(.enableUpcomingFeature("MemberImportVisibility"))
6667
target.swiftSettings = settings
68+
case .macro, .plugin, .system, .binary:
69+
() // not applicable
70+
@unknown default:
71+
() // we don't know what to do here, do nothing
6772
}
6873
}
6974
// --- END: STANDARD CROSS-REPO SETTINGS DO NOT EDIT --- //

0 commit comments

Comments
 (0)