[libc-commits] [libc] [libc] Add a small utility type in __support/ called InlineAny. (PR #223490)
via libc-commits
libc-commits at lists.llvm.org
Mon Sep 14 11:50:14 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 -- libc/src/__support/inline_any.h libc/test/src/__support/inline_any_test.cpp libc/src/__support/CPP/type_traits/is_trivially_constructible.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/libc/src/__support/inline_any.h b/libc/src/__support/inline_any.h
index efc43e5c9..2758a20ec 100644
--- a/libc/src/__support/inline_any.h
+++ b/libc/src/__support/inline_any.h
@@ -22,8 +22,8 @@ namespace LIBC_NAMESPACE_DECL {
// A utility providing inline storage for a type-erased value with trivial type.
//
// The maximum size and alignment of stored types is controlled by `Size` and
-// `Alignment`. Does not store or check any type information for the saved value.
-// Example:
+// `Alignment`. Does not store or check any type information for the saved
+// value. Example:
//
// InlineAny<20> any;
// any.store(5.0);
``````````
</details>
https://github.com/llvm/llvm-project/pull/223490
More information about the libc-commits
mailing list