[libcxx-commits] [libcxx] [libc++] Suppress deprecation warning around wstring_convert::to_bytes (PR #201633)
via libcxx-commits
libcxx-commits at lists.llvm.org
Thu Jun 4 09:54:17 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,cpp -- libcxx/test/libcxx/localization/locales/locale.convenience/conversions/conversions.string/pragma_suppress.compile.pass.cpp libcxx/include/__locale_dir/wstring_convert.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/test/libcxx/localization/locales/locale.convenience/conversions/conversions.string/pragma_suppress.compile.pass.cpp b/libcxx/test/libcxx/localization/locales/locale.convenience/conversions/conversions.string/pragma_suppress.compile.pass.cpp
index 8e2cc7128..5dacb49e7 100644
--- a/libcxx/test/libcxx/localization/locales/locale.convenience/conversions/conversions.string/pragma_suppress.compile.pass.cpp
+++ b/libcxx/test/libcxx/localization/locales/locale.convenience/conversions/conversions.string/pragma_suppress.compile.pass.cpp
@@ -23,8 +23,8 @@
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wdeprecated-declarations"
void test() {
- std::wstring_convert<std::codecvt_utf8_utf16<char16_t>, char16_t> converter;
- (void)converter.to_bytes(std::basic_string<char16_t>(u"hello"));
- (void)converter.from_bytes(std::string("hello"));
+ std::wstring_convert<std::codecvt_utf8_utf16<char16_t>, char16_t> converter;
+ (void)converter.to_bytes(std::basic_string<char16_t>(u"hello"));
+ (void)converter.from_bytes(std::string("hello"));
}
#pragma clang diagnostic pop
``````````
</details>
https://github.com/llvm/llvm-project/pull/201633
More information about the libcxx-commits
mailing list