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

Correct handling of context-sensitive unicode case folding #11

Open
djudd opened this issue Jul 15, 2022 · 2 comments
Open

Correct handling of context-sensitive unicode case folding #11

djudd opened this issue Jul 15, 2022 · 2 comments

Comments

@djudd
Copy link
Owner

djudd commented Jul 15, 2022

There are a couple of places where we ignore the fact that unicode case folding can generate multiple characters, and I don't think there are any cases where we correctly handle context. rust-lang/rust#98490 would make this much easier.

@djudd
Copy link
Owner Author

djudd commented Jul 15, 2022

A little more research suggests what we actually want is case folding, e.g. via https://github.com/unicode-rs/rust-caseless. But this might be slower (particularly given need for a different normalization) and it's not clear if it really matters given that we're often running against already transliterated data, or only interested in an initial.

@djudd
Copy link
Owner Author

djudd commented Jul 18, 2022

#20 makes us consistently respect the possibility of multiple characters for a case mapping, but I'll leave this open to handle context.

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

No branches or pull requests

1 participant