[clang] [clang][bytecode] Char<Signed> doesn't need a descriptor ctor (PR #203748)

via cfe-commits cfe-commits at lists.llvm.org
Sat Jun 13 23:57:53 PDT 2026


llvmorg-github-actions[bot] wrote:


<!--LLVM PR SUMMARY COMMENT-->

@llvm/pr-subscribers-clang

Author: Timm Baeder (tbaederr)

<details>
<summary>Changes</summary>

This was lost when adding Char for 8-bit data.

---
Full diff: https://github.com/llvm/llvm-project/pull/203748.diff


1 Files Affected:

- (modified) clang/lib/AST/ByteCode/Descriptor.cpp (+2-2) 


``````````diff
diff --git a/clang/lib/AST/ByteCode/Descriptor.cpp b/clang/lib/AST/ByteCode/Descriptor.cpp
index dfe539ca85e04..8c5bb1af869d1 100644
--- a/clang/lib/AST/ByteCode/Descriptor.cpp
+++ b/clang/lib/AST/ByteCode/Descriptor.cpp
@@ -23,8 +23,8 @@ using namespace clang;
 using namespace clang::interp;
 
 template <typename T> static constexpr bool needsCtor() {
-  if constexpr (std::is_same_v<T, Integral<8, true>> ||
-                std::is_same_v<T, Integral<8, false>> ||
+  if constexpr (std::is_same_v<T, Char<true>> ||
+                std::is_same_v<T, Char<false>> ||
                 std::is_same_v<T, Integral<16, true>> ||
                 std::is_same_v<T, Integral<16, false>> ||
                 std::is_same_v<T, Integral<32, true>> ||

``````````

</details>


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


More information about the cfe-commits mailing list