[libc-commits] [libc] [libc] Implemented wcsdup libc function (PR #150453)

via libc-commits libc-commits at lists.llvm.org
Thu Jul 24 09:33:25 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 -- libc/src/wchar/wcsdup.cpp libc/src/wchar/wcsdup.h libc/test/src/wchar/wcsdup_test.cpp libc/src/string/allocating_string_utils.h
``````````

</details>

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

``````````diff
diff --git a/libc/src/wchar/wcsdup.cpp b/libc/src/wchar/wcsdup.cpp
index cbe204f0e..d4a13d35e 100644
--- a/libc/src/wchar/wcsdup.cpp
+++ b/libc/src/wchar/wcsdup.cpp
@@ -15,7 +15,7 @@
 
 namespace LIBC_NAMESPACE_DECL {
 
-LLVM_LIBC_FUNCTION(wchar_t *, wcsdup, (const wchar_t * wcs)) {
+LLVM_LIBC_FUNCTION(wchar_t *, wcsdup, (const wchar_t *wcs)) {
   auto dup = internal::strdup(wcs);
   if (dup)
     return *dup;

``````````

</details>


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


More information about the libc-commits mailing list