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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor: 馃挕 maybe perf a bit #7

Conversation

IWANABETHATGUY
Copy link
Contributor

No description provided.

@@ -58,11 +58,12 @@ pub trait CodeGenWrite: Write {
for c in s.chars() {
if !is_boundary && c.is_ascii_uppercase() {
self.write_char('-')?;
self.write_char((c as u8 - b'A' + b'a') as char)?;
self.write_char(c.to_ascii_lowercase())?;
is_boundary = false;
Copy link
Contributor Author

Choose a reason for hiding this comment

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

in this branch, is_boundry will always be false, due to c.is_ascii_alphanumeric is true.

@HerringtonDarkholme HerringtonDarkholme merged commit c6b0467 into HerringtonDarkholme:main Sep 9, 2021
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.

None yet

2 participants