Skip to content

Adopt CasePath protocol - #373

Merged
stephencelis merged 7 commits into
mainfrom
case-path-protocol
Aug 31, 2026
Merged

stephencelis merged 7 commits into
mainfrom
case-path-protocol

Conversation

@stephencelis

Copy link
Copy Markdown
Member

This upcoming protocol allows for better compatibility between CasePaths 1.0 and the upcoming 2.0.

Draft till a new minor version of CasePaths (1.10.0) lands.

This upcoming protocol allows for better compatibility between CasePaths 1.0 and the upcoming 2.0.
@stephencelis
stephencelis requested a review from mbrandonw August 27, 2026 18:12
base: Base, keyPath: _SendableKeyPath<Base.Value.AllCasePaths, AnyCasePath<Base.Value, Case>>
) {
let keyPath: _SendableKeyPath<Base.Value.AllCasePaths, Path>
nonisolated(unsafe) let casePath: Path

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This unsafe is just till we get a handle on #321. AnyCasePath is sendable in 1.0, and case path conformances are sendable in 2.0.

@stephencelis
stephencelis marked this pull request as ready for review August 31, 2026 17:43
@stephencelis
stephencelis merged commit 7e95e5e into main Aug 31, 2026
5 checks passed
@stephencelis
stephencelis deleted the case-path-protocol branch August 31, 2026 18:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants