-
Notifications
You must be signed in to change notification settings - Fork 117
Introduce a new ABI.VersionNumber
type.
#1239
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
This PR introduces and plumbs through an internal `ABI.VersionNumber` type that represents the JSON event stream version that should be used during a test run. This type supports integers (such as the current version 0) and semantic versions (e.g. 6.3 or 6.3.0). Care is taken to ensure backwards compatibility for ABI versions -1 and 0 which do not accept a string in this position. > [!WARNING] > For technical reasons involving `__CommandLineArguments_v0`, this type is > exposed publicly as `__ABIVersionNumber`. This typealias may be removed in a > future update. The new type necessarily conforms to `Comparable` and `Codable`. It also conforms to `ExpressibleByIntegerLiteral` for compatibility with older versions of Xcode that set the `__CommandLineArguments_v0.eventStreamVersion` property to an integer literal value. For the moment, these are all implementation details that have no impact on our supported interface as there is no newer JSON schema than 0. We intend to make changes to the schema in the next Swift release (assumed to be 6.3) that will require a Swift Evolution review.
@swift-ci test |
@swift-ci test |
@swift-ci test |
@swift-ci test |
@swift-ci test |
…d 0) and public keyword
@swift-ci test |
@swift-ci test |
@swift-ci test |
@swift-ci test |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, thank you for the iteration! My final comment was that I thought explicit labels e.g. majorComponent:...
for the initializer usages would be helpful, but it's stylistic and I leave it up to you
@swift-ci test |
macOS CI is backlogged. Tested at desk. |
This PR introduces and plumbs through an internal
ABI.VersionNumber
type that represents the JSON event stream version that should be used during a test run. This type supports integers (such as the current version 0) and semantic versions (e.g. 6.3 or 6.3.0). Care is taken to ensure backwards compatibility for ABI versions -1 and 0 which do not accept a string in this position.The new type necessarily conforms to
Comparable
andCodable
. I've adjusted__CommandLineArguments_v0
to support this new type while maintaining backwards-compatibility with Xcode 16.For the moment, these are all implementation details that have no impact on our supported interface as there is no newer JSON schema than 0. We intend to make changes to the schema in the next Swift release (assumed to be 6.3) that will require a Swift Evolution review.
Checklist: