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
Port "match" package #6
Comments
Just a tip, but I rewrote the match function for C. It may be a better point of reference. https://github.com/tidwall/match.c/blob/master/match.c#L19 It does not include all of the weird utf8 "rune" stuff, which is probably not needed with Rust anyhow because Rust Strings are inherently sane. |
Ah perfect! This should be very helpful. |
Unless you plan on implementing it to be used on raw bytes, then you will probably need some kind of utf8 character reader. |
So I ended up porting the C version, but it turns out |
match
is used when matching indexes and should be ported as a utility modulematcher.rs
(match
is a keyword in Rust so it would require prefixing each occurrence withr#
).The text was updated successfully, but these errors were encountered: