[libcxx-commits] [libcxx] [libcxx] fix missing `__get_locale_encoding()` for OpenBSD (PR #228306)

via libcxx-commits libcxx-commits at lists.llvm.org
Thu Oct 1 19:20:20 PDT 2026


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 origin/main HEAD --extensions h -- libcxx/include/__locale_dir/support/openbsd.h --diff_from_common_commit
``````````

:warning:
The reproduction instructions above might return results for more than one PR
in a stack if you are using a stacked PR workflow. You can limit the results by
changing `origin/main` to the base branch/commit you want to compare against.
:warning:

</details>

<details>
<summary>
View the diff from clang-format here.
</summary>

``````````diff
diff --git a/libcxx/include/__locale_dir/support/openbsd.h b/libcxx/include/__locale_dir/support/openbsd.h
index b22cdf38b..e0b31dd0d 100644
--- a/libcxx/include/__locale_dir/support/openbsd.h
+++ b/libcxx/include/__locale_dir/support/openbsd.h
@@ -79,7 +79,7 @@ inline __lconv_t* __localeconv(__locale_t& __loc) {
 }
 
 inline _LIBCPP_HIDE_FROM_ABI const char* __get_locale_encoding(__locale_t __loc) {
-    return ::nl_langinfo_l(CODESET, __loc);
+  return ::nl_langinfo_l(CODESET, __loc);
 }
 #endif // _LIBCPP_BUILDING_LIBRARY
 

``````````

</details>


https://github.com/llvm/llvm-project/pull/228306


More information about the libcxx-commits mailing list