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

perf: remove unnecessary .c_str() calls #41869

Merged
merged 8 commits into from
Apr 16, 2024

Conversation

ckerr
Copy link
Member

@ckerr ckerr commented Apr 15, 2024

Description of Change

Minor perf cleanup for cases where we have a string or wstring foo and pass it to a method that takes a std::string_view with foo.c_str() instead of just foo. Passing the string is preferable since its length is already known and won't have to be recomputed from the const char*.

All reviews welcome; no specific individual stakeholders.

Checklist

Release Notes

Notes: none.

@ckerr ckerr added performance 🏁 target/30-x-y PR should also be added to the "30-x-y" branch. labels Apr 15, 2024
@electron-cation electron-cation bot added the new-pr 🌱 PR opened in the last 24 hours label Apr 15, 2024
…er::UpdateSourcesList()

this conversion was made redundant by c670e38
@ckerr ckerr added no-backport semver/patch backwards-compatible bug fixes and removed target/30-x-y PR should also be added to the "30-x-y" branch. labels Apr 15, 2024
@electron-cation electron-cation bot removed the new-pr 🌱 PR opened in the last 24 hours label Apr 16, 2024
@jkleinsc jkleinsc merged commit b428315 into main Apr 16, 2024
20 checks passed
@jkleinsc jkleinsc deleted the perf/remove-unnecessary-c_str()-calls branch April 16, 2024 23:48
Copy link

release-clerk bot commented Apr 16, 2024

No Release Notes

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

Successfully merging this pull request may close these issues.

None yet

3 participants