Skip to content
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

partition ASCII and non-ASCII byte classes when a Unicode word boundary is used #652

Closed
BurntSushi opened this issue Mar 10, 2020 · 1 comment
Labels

Comments

@BurntSushi
Copy link
Member

From this issue BurntSushi/ripgrep#1513, it was discovered that the DFA would quit when the regex contains a Unicode word boundary even when the input was purely ASCII. It turns out that characters like | and { and } would get lumped into the same byte equivalence class as non-ASCII bytes, which would cause the DFA's non-ASCII circuit to trip and quit the DFA.

This should be easyish to fix. If the regex has a Unicode word boundary, then ensure that ASCII bytes are never lumped into the same equivalence class as non-ASCII bytes.

@BurntSushi
Copy link
Member Author

This appears to have been fixed in #768. (It is also fixed in regex-automata.)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant