Skip to content

Commit ae271ca

Browse files
committed
Guard the option correctly
1 parent c4fc7ca commit ae271ca

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

Sources/SwiftDriver/Jobs/FrontendJobHelpers.swift

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -266,7 +266,9 @@ extension Driver {
266266
if isFrontendArgSupported(.noAllocations) {
267267
try commandLine.appendLast(.noAllocations, from: &parsedOptions)
268268
}
269-
try commandLine.appendLast(.compilerAssertions, from: &parsedOptions)
269+
if isFrontendArgSupported(.compilerAssertions) {
270+
try commandLine.appendLast(.compilerAssertions, from: &parsedOptions)
271+
}
270272
if isFrontendArgSupported(.enableExperimentalFeature) {
271273
try commandLine.appendAll(
272274
.enableExperimentalFeature, from: &parsedOptions)

0 commit comments

Comments
 (0)