mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
Allow `@_section` and `@_used` to be used in fully constrained extensions.
This aligns with the existing behavior of static properties of generic types. The following is valid:
```swift
extension Array where Element == Int {
static let specificConstant = 41
}
```
However, adding `@_section` or `@_used` to the above property, will result in an error diagnostic.
This change updates the logic of `@_section`/`@_used` to allow their use when the generic context is fully concrete.
2.6 KiB
2.6 KiB