Skip to content

Commit 8586e98

Browse files
authored
Simplify an expression which triggers complexity errors in nightly toolchains (swiftlang#36)
1 parent b13c3c6 commit 8586e98

File tree

1 file changed

+17
-1
lines changed

1 file changed

+17
-1
lines changed

Sources/SWBApplePlatform/Specs/AssetCatalogCompiler.swift

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -415,7 +415,23 @@ public final class ActoolCompilerSpec : GenericCompilerSpec, SpecIdentifierType,
415415
return
416416
}
417417

418-
delegate.createTask(type: self, dependencyData: .dependencyInfo(Path(dependencyInfoPath())), ruleInfo: ["LinkAssetCatalog"] + cbc.inputs.flatMap { [$0.absolutePath.str] }, commandLine: ["builtin-linkAssetCatalog"] + variants.flatMap { ["--\($0.variant.rawValue)", $0.node.path.str, "--\($0.variant.rawValue)-dependencies", dependencyInfoPath(variant: $0.variant), "--\($0.variant.rawValue)-info-plist-content", infoPlistContentPath(variant: $0.variant)] } + ["--output", cbc.scope.evaluate(BuiltinMacros.UnlocalizedProductResourcesDir, lookup: { self.lookup($0, cbc, delegate) }).str, "--plist-output", plistOutputPath.str], environment: environmentFromSpec(cbc, delegate), workingDirectory: cbc.producer.defaultWorkingDirectory, inputs: realInputs() + variants.map(\.node) + [delegate.createNode(signaturePath)], outputs: realOutputs, action: delegate.taskActionCreationDelegate.createLinkAssetCatalogTaskAction(), execDescription: "Link asset catalogs", preparesForIndexing: false, enableSandboxing: false, llbuildControlDisabled: true)
418+
let commandLine: [String] = ["builtin-linkAssetCatalog"] + variants.flatMap { ["--\($0.variant.rawValue)", $0.node.path.str, "--\($0.variant.rawValue)-dependencies", dependencyInfoPath(variant: $0.variant), "--\($0.variant.rawValue)-info-plist-content", infoPlistContentPath(variant: $0.variant)] } + ["--output", cbc.scope.evaluate(BuiltinMacros.UnlocalizedProductResourcesDir, lookup: { self.lookup($0, cbc, delegate) }).str, "--plist-output", plistOutputPath.str]
419+
420+
delegate.createTask(
421+
type: self,
422+
dependencyData: .dependencyInfo(Path(dependencyInfoPath())),
423+
ruleInfo: ["LinkAssetCatalog"] + cbc.inputs.flatMap { [$0.absolutePath.str] },
424+
commandLine: commandLine,
425+
environment: environmentFromSpec(cbc, delegate),
426+
workingDirectory: cbc.producer.defaultWorkingDirectory,
427+
inputs: realInputs() + variants.map(\.node) + [delegate.createNode(signaturePath)],
428+
outputs: realOutputs,
429+
action: delegate.taskActionCreationDelegate.createLinkAssetCatalogTaskAction(),
430+
execDescription: "Link asset catalogs",
431+
preparesForIndexing: false,
432+
enableSandboxing: false,
433+
llbuildControlDisabled: true
434+
)
419435
}
420436
}
421437

0 commit comments

Comments
 (0)