Version 1.7.0 of this package fails to compile on Xcode 15 / Swift 5.9, despite the README for this package claiming Swift 5.7+ are supported.
The cause of the compile failure seems to be the use of "scoped imports" introduced in version 1.7.0. See:
https://github.com/apple/swift-argument-parser/pull/804/changes#diff-1d30222d502b2ce39bb68017a7c60ce161ea2dd19e662f10631b136192eb0dd2R15
Scoped imports are apparently experimental in Swift 5.x and require the use of compiler flags to compile successfully.
I experienced this issue on Swift 5.9, but I'm presuming other Swift 5.x versions on Mac have the same issue. This seems to only be a Mac issue, since Swift 5.9 on Linux compiles version 1.7.0 successfully (the scoped import seems to be excluded by compile conditions on Linux.)
ArgumentParser version: 1.7.0
Swift version:
Apple Swift version 5.9.2 (swiftlang-5.9.2.2.56 clang-1500.1.0.2.5)
Target: arm64-apple-macosx14.0
Checklist
Steps to Reproduce
Expected behavior
Package builds on Swift 5.9 without compile errors
Actual behavior
Package fails on Swift 5.9 with compile error:
Error: Access level on imports require '-enable-experimental-feature AccessLevelOnImport'
internal import os
^~~~~~~~~
Version 1.7.0 of this package fails to compile on Xcode 15 / Swift 5.9, despite the README for this package claiming Swift 5.7+ are supported.
The cause of the compile failure seems to be the use of "scoped imports" introduced in version 1.7.0. See:
https://github.com/apple/swift-argument-parser/pull/804/changes#diff-1d30222d502b2ce39bb68017a7c60ce161ea2dd19e662f10631b136192eb0dd2R15
Scoped imports are apparently experimental in Swift 5.x and require the use of compiler flags to compile successfully.
I experienced this issue on Swift 5.9, but I'm presuming other Swift 5.x versions on Mac have the same issue. This seems to only be a Mac issue, since Swift 5.9 on Linux compiles version 1.7.0 successfully (the scoped import seems to be excluded by compile conditions on Linux.)
ArgumentParser version:
1.7.0Swift version:
Checklist
mainbranch of this packageSteps to Reproduce
Expected behavior
Package builds on Swift 5.9 without compile errors
Actual behavior
Package fails on Swift 5.9 with compile error: