-
Notifications
You must be signed in to change notification settings - Fork 10.5k
SR-10689: Fix bugs of DataProtocol's firstRange(of:in:)/lastRange(of:in:). #28639
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
@swift-ci please test |
Build failed |
I'm sorry. The failure is caused by my rudimentary mistake. I'll fix it. |
…f:in:) to fix SR-10689. Cherry-pick from swiftlang/swift-corelibs-foundation#2499
0a5e93e
to
421af22
Compare
I am sorry for the late fix. Now it is rebased and would pass tests. |
All tests of this PR and scf#2499 have passed. |
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.
Looks good to me
@phausler |
DataProtocol
'sfirstRange(of:in:)
andlastRange(of:in:)
return a wrong value or crash under some conditions because they handle indices incorrectly.Resolves SR-10689.
Note: This PR is a counterpart of swiftlang/swift-corelibs-foundation#2499 .