Closed kudit closed 5 months ago
Added check for building on macOS (without catalyst) so it will not generate errors. The Swift < 5.9 checks aren't necessary with the new version of Swift Playgrounds, but it probably would be good to keep for a bit in case someone is using an older version.
@kudit Your PR contains a lot of other changes. In its current state it won't be merged.
In Swift Playgrounds (which doesn't yet support Swift 5.9), there is a warning that the OS is not supported since it doesn't know about xrOS (visionOS): "Unknown operating system for build configuration 'os'". I've re-worked the conditional compiles to look for the module UIScreen which is more appropriate rather than the OS tests and added a Swift version compiler check for the case that isn't module dependent. The last area is a bit redundant but I wasn't sure how to structure the statements without the redundancy since you can't do #if os(visionOS) without doing #if swift(>=5.9) first and separately.