[libunwind] [libunwind][AIX] Cast NULL as type uintptr_t. (PR #93204)
Xing Xue via cfe-commits
cfe-commits at lists.llvm.org
Thu May 23 08:06:54 PDT 2024
https://github.com/xingxue-ibm created https://github.com/llvm/llvm-project/pull/93204
Casting NULL as type `uintptr_t` to allow type checking in both 32-bit and 64-bit mode.
>From 1e21301d3b07bd72696f39a0ca8cd19907cdcf71 Mon Sep 17 00:00:00 2001
From: Xing Xue <xingxue at outlook.com>
Date: Thu, 23 May 2024 10:51:32 -0400
Subject: [PATCH] Cast NULL as type uintptr_t.
---
libunwind/src/UnwindCursor.hpp | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/libunwind/src/UnwindCursor.hpp b/libunwind/src/UnwindCursor.hpp
index 7753936a5894a..66fe8e2a32cca 100644
--- a/libunwind/src/UnwindCursor.hpp
+++ b/libunwind/src/UnwindCursor.hpp
@@ -2416,7 +2416,7 @@ int UnwindCursor<A, R>::stepWithTBTable(pint_t pc, tbtable *TBTable,
}
// Reset LR in the current context.
- newRegisters.setLR(NULL);
+ newRegisters.setLR(static_cast<uintptr_t>(NULL));
_LIBUNWIND_TRACE_UNWINDING(
"Extract info from lastStack=%p, returnAddress=%p",
More information about the cfe-commits
mailing list