When using Swift Tools version 6.2 to enable warnings as errors:
targets: [
.target(
name: "MyLib",
dependencies: [
.product(
name: "SomeDependencyWithWarnings",
package: "some-dependency"
)
],
swiftSettings: [
.treatAllWarnings(as: .error) // ππ»
]
),
We are failing to build if the dependency has warnings (repo of the issue can be found here).
In practice this is happening for a transitive dependency deep on the dependency chain in code we donβt own so patching is not an option. The dependency ships as a binary target with Objective-C headers which I suspect is relevant.
Is anybody else experiencing this and is there a suggested work around that would allow preservation of treating warnings as errors?