https://github.com/tbaederr created 
https://github.com/llvm/llvm-project/pull/147942

This is easier to read in debuggers and more common.

>From c2f5d0eb65d0f6b291ccfa41603f9800fda6a756 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Timm=20B=C3=A4der?= <tbae...@redhat.com>
Date: Thu, 10 Jul 2025 13:52:10 +0200
Subject: [PATCH] [clang][bytecode][NFC] Move Pointer::StorageKind above the
 union

This is easier to read in debuggers and more common.
---
 clang/lib/AST/ByteCode/Pointer.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/clang/lib/AST/ByteCode/Pointer.h b/clang/lib/AST/ByteCode/Pointer.h
index d525f84fd6605..e6a64e6658f06 100644
--- a/clang/lib/AST/ByteCode/Pointer.h
+++ b/clang/lib/AST/ByteCode/Pointer.h
@@ -809,13 +809,13 @@ class Pointer {
   /// Next link in the pointer chain.
   Pointer *Next = nullptr;
 
+  Storage StorageKind = Storage::Int;
   union {
     BlockPointer BS;
     IntPointer Int;
     FunctionPointer Fn;
     TypeidPointer Typeid;
   } PointeeStorage;
-  Storage StorageKind = Storage::Int;
 };
 
 inline llvm::raw_ostream &operator<<(llvm::raw_ostream &OS, const Pointer &P) {

_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to