[clang] [Clang][Bytecode] Match exact void pointer deref error message (PR #166133)

via cfe-commits cfe-commits at lists.llvm.org
Mon Nov 3 04:22:27 PST 2025


llvmbot wrote:


<!--LLVM PR SUMMARY COMMENT-->

@llvm/pr-subscribers-clang

Author: Tomer Shafir (tomershafir)

<details>
<summary>Changes</summary>

Better match exactly rather than just a prefix.

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


1 Files Affected:

- (modified) clang/test/AST/ByteCode/cxx11.cpp (+1-1) 


``````````diff
diff --git a/clang/test/AST/ByteCode/cxx11.cpp b/clang/test/AST/ByteCode/cxx11.cpp
index 427d3a106656b..e283a7b42e554 100644
--- a/clang/test/AST/ByteCode/cxx11.cpp
+++ b/clang/test/AST/ByteCode/cxx11.cpp
@@ -374,7 +374,7 @@ namespace GH150709 {
 namespace DiscardedAddrLabel {
   void foo(void) {
   L:
-    *&&L; // both-error {{indirection not permitted}} \
+    *&&L; // both-error {{indirection not permitted on operand of type 'void *'}} \
           // both-warning {{expression result unused}}
   }
 }

``````````

</details>


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


More information about the cfe-commits mailing list