Swift gives developers a way to limit the use of declarations in certain contexts using the @available attribute. For example, a library developer can specify that a new API is only available at runtime on macOS 15 or newer using @available: @available(macOS, introduced: 15) public struct Foo { /* ... */ } The compiler only accepts references ...