mirror of
https://github.com/apple/swift-log
synced 2026-11-23 03:44:22 +00:00
Enable several upcoming compiler features to make the codebase more
explicit in intention:
```
// https://github.com/apple/swift-evolution/blob/main/proposals/0335-existential-any.md
// Require `any` for existential types.
settings.append(.enableUpcomingFeature("ExistentialAny"))
// https://github.com/swiftlang/swift-evolution/blob/main/proposals/0444-member-import-visibility.md
settings.append(.enableUpcomingFeature("MemberImportVisibility"))
// https://github.com/swiftlang/swift-evolution/blob/main/proposals/0409-access-level-on-imports.md
settings.append(.enableUpcomingFeature("InternalImportsByDefault"))
// https://docs.swift.org/compiler/documentation/diagnostics/nonisolated-nonsending-by-default/
settings.append(.enableUpcomingFeature("NonisolatedNonsendingByDefault"))
// Ensure all public types are explicitly annotated as Sendable or not Sendable.
settings.append(.unsafeFlags(["-Xfrontend", "-require-explicit-sendable"]))
```
### Motivation:
Sync codebase with the modern practice, get ready for the upcoming
features.
### Modifications:
- Compiler flags added for all the existing targets.
- Imports and access modifiers adjusted.
- `LoggingSystem` marked as `Sendable`
### Result:
Codebase is updated with the modern practices.