[clang] [clang][Interp] Integral pointers (PR #84159)

Timm Baeder via cfe-commits cfe-commits at lists.llvm.org
Wed Mar 13 23:13:26 PDT 2024


Timm =?utf-8?q?B=C3=A4der?= <tbaeder at redhat.com>,
Timm =?utf-8?q?B=C3=A4der?= <tbaeder at redhat.com>
Message-ID:
In-Reply-To: <llvm.org/llvm/llvm-project/pull/84159 at github.com>


================
@@ -53,6 +57,10 @@ class FunctionPointer final {
     return toAPValue().getAsString(Ctx, Func->getDecl()->getType());
   }
 
+  uint32_t getIntegerRepresentation() const {
+    return static_cast<uint32_t>(reinterpret_cast<uintptr_t>(Func));
+  }
----------------
tbaederr wrote:

Same comment as below - it should probably be a 64bit int?

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


More information about the cfe-commits mailing list