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

feat: Make s-string select req case insensitive #1444

Merged

Conversation

BlurrechDev
Copy link
Contributor

Attempts to close #1439

Uses eq_ignore_ascii_case to confirm the prefix is correct.
Adds two tests for "select" and "sElEcT". (We have plenty of "SELECT" coverage already.)
Very new to Rust so if anything I do is contrived please let me know so I can learn 👍

Take 2 with formatting corrected.

Copy link
Member

@max-sixty max-sixty left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great! Thanks a lot @BlurrechDev

If you're up for adding an entry in changelog as a follow-up, then great, otherwise I can add one when I do a release.

(BTW no need to close the previous one and reopen a new one, it's always fine to push more commits. But zero stress!)

locks: vec![],
})

let prefix = if let Some(string) = string.trim().get(0..7) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, I think we probably do need this 0..7 here, even though it's a bit awkward. The alternative would be upper case the whole string and feed it into the existing function, but this is more than fine.

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

Successfully merging this pull request may close these issues.

S-string table creation case sensitivity
2 participants