Make requirements static to prepare for 2.0 - #258
Merged
Conversation
Currently, completing from a case key path from `\.` returns a bunch of extra endpoints due to the `Sequence` requirements of `AllCasePaths` leaking through, as well as the subscript used to look up the case path for a particular case: - `lazy` - `publisher` - `underestimatedCount` - `[_:]` This is a lot of noise that gets in the way, so let's rethink things: - Iterating over all of an enum's case paths now requires an explicit `Array(Enum.allCasePaths)`. - Getting a particular case of an enum is already achievable via `enum.case`, so we can make that the main requirement.
mbrandonw
approved these changes
Sep 2, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Currently, completing from a case key path from
\.returns a bunch of extra endpoints due to theSequencerequirements ofAllCasePathsleaking through, as well as the subscript used to look up the case path for a particular case:lazypublisherunderestimatedCount[_:]This is a lot of noise that gets in the way, so let's rethink things:
Array(Enum.allCasePaths).enum.case, so we can make that the main requirement.