Files
swift-crypto/Sources/CryptoExtras/Digests/BoringSSL
Si Beaumont ad74759b96 Silence ImplementationOnlyDeprecated for Swift 6.4+
This project is currently warnings-as-errors clean, but only because we
suppress `ImplementationOnlyDeprecated` warnings, using the following:

```
-Xswiftc -warnings-as-errors -Xswiftc -Wwarning -Xswiftc ImplementationOnlyDeprecated
```

With this setup, the warnings are still generated and are noisy.

Swift 6.4 introduces `SourceWarningControl`, which we can use to
actually _silence_ these warnings, using `@diagnose(_:as:)`.

This patch adds a dance around the `@_implementationOnly imports`:

    #if hasFeature(SourceWarningControl)
    @diagnose(ImplementationOnlyDeprecated, as: ignored)
    #endif
    @_implementationOnly import ...

On Swift 6.4, this project is now warnings free.

When we raise the minimum supported Swift compiler version to one that
supports `SourceWarningControl`, we can remove the `#if hasFeature`
guards.
2026-08-06 14:16:47 +01:00
..