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

Update StaticUtils#toLowerCase #241

Merged
merged 1 commit into from
Feb 14, 2025
Merged

Conversation

kqarryzada
Copy link
Collaborator

The previous implementation of StaticUtils.toLowerCase() was optimized for ASCII characters. However, this no longer appears to provide a reasonable performance benefit in comparison to passing the call to the JDK. More background on this is available on Jira.

Reviewer: vyhhuang
Reviewer: dougbulkley

JiraIssue: DS-49717

@kqarryzada kqarryzada self-assigned this Feb 13, 2025
Copy link

@vyhhuang vyhhuang left a comment

Choose a reason for hiding this comment

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

These changes look good to me.

// These test cases are not extensive since the method is a wrapper around
// the String#toLowercase() from the JDK.
assertThat(StaticUtils.toLowerCase("lowerstring")).isEqualTo("lowerstring");
assertThat(StaticUtils.toLowerCase("sPoNgEbOb tExT"))

Choose a reason for hiding this comment

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

lol

The previous implementation of StaticUtils.toLowerCase() was optimized
for ASCII characters. However, this no longer appears to provide a
reasonable performance benefit in comparison to passing the call to the
JDK. More background on this is available on Jira.

Reviewer: vyhhuang
Reviewer: dougbulkley

JiraIssue: DS-49717
@kqarryzada kqarryzada force-pushed the DS-49717-update-lowercase branch from dd5ab0b to 4b1fc5a Compare February 14, 2025 00:22
@kqarryzada kqarryzada merged commit 14e1197 into master Feb 14, 2025
10 checks passed
@kqarryzada kqarryzada deleted the DS-49717-update-lowercase branch February 14, 2025 16:49
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.

3 participants