-
Notifications
You must be signed in to change notification settings - Fork 49
Add UTF8 byte matching optimization #787
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
|
For FSPathsRegex, prior to this the hottest past was |
self.utf8.formIndex(after: &cur) | ||
} | ||
|
||
guard cur <= end else { return nil } |
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.
I think this could be an assertion, but it's probably fine here.
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.
Nice!
@swift-ci please test |
Adds a new instruction to match a sequence of UTF-8 bytes directly, rather than individual match-scalar calls.