Skip to content

Make offset a required parameter in Indexable#find#15671

Merged
straight-shoota merged 1 commit intocrystal-lang:masterfrom
straight-shoota:chore/indexable-find-offset
Apr 19, 2025
Merged

Make offset a required parameter in Indexable#find#15671
straight-shoota merged 1 commit intocrystal-lang:masterfrom
straight-shoota:chore/indexable-find-offset

Conversation

@straight-shoota
Copy link
Member

Since 1.16.0, Indexable#find provides the offset parameter as an additional feature over Enumerable#find.
Calls that do not make use of this parameter don't need the added complexity of offset handling. They should fall back to the base implementation in Enumerable#find.

To achieve that, this patch makes offset a required parameter for Indexable#find.

@straight-shoota straight-shoota added this to the 1.17.0 milestone Apr 17, 2025
@straight-shoota straight-shoota merged commit 6538188 into crystal-lang:master Apr 19, 2025
36 checks passed
@straight-shoota straight-shoota deleted the chore/indexable-find-offset branch May 20, 2025 21:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants