[libcxx-commits] [libcxx] [libc++] Optimize ctype::to{lower, upper} (PR #145344)
via libcxx-commits
libcxx-commits at lists.llvm.org
Mon Jun 23 08:43:38 PDT 2025
github-actions[bot] wrote:
<!--LLVM CODE FORMAT COMMENT: {clang-format}-->
:warning: C/C++ code formatter, clang-format found issues in your code. :warning:
<details>
<summary>
You can test this locally with the following command:
</summary>
``````````bash
git-clang-format --diff HEAD~1 HEAD --extensions ,cpp,h -- libcxx/test/benchmarks/locale/ctype.bench.cpp libcxx/include/__config libcxx/include/__locale_dir/locale_base_api.h libcxx/include/__locale_dir/support/bsd_like.h libcxx/include/__locale_dir/support/linux.h libcxx/include/__locale_dir/support/no_locale/characters.h libcxx/include/__locale_dir/support/windows.h libcxx/src/locale.cpp
``````````
</details>
<details>
<summary>
View the diff from clang-format here.
</summary>
``````````diff
diff --git a/libcxx/src/locale.cpp b/libcxx/src/locale.cpp
index a36297bc8..24fb37d7b 100644
--- a/libcxx/src/locale.cpp
+++ b/libcxx/src/locale.cpp
@@ -748,9 +748,7 @@ const wchar_t* ctype<wchar_t>::do_toupper(char_type* low, const char_type* high)
return low;
}
-wchar_t ctype<wchar_t>::do_tolower(char_type c) const {
- return to_lower_impl(c);
-}
+wchar_t ctype<wchar_t>::do_tolower(char_type c) const { return to_lower_impl(c); }
const wchar_t* ctype<wchar_t>::do_tolower(char_type* low, const char_type* high) const {
for (; low != high; ++low)
``````````
</details>
https://github.com/llvm/llvm-project/pull/145344
More information about the libcxx-commits
mailing list