[clang] [clang][bytecode] Move a local variable to a later point (PR #121250)
Timm Baeder via cfe-commits
cfe-commits at lists.llvm.org
Fri Dec 27 21:42:57 PST 2024
https://github.com/tbaederr created https://github.com/llvm/llvm-project/pull/121250
We don't need `E` before.
>From 3ecbfa862eee6b6c1f009dfcf6b9791e77af97b4 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Timm=20B=C3=A4der?= <tbaeder at redhat.com>
Date: Sat, 28 Dec 2024 06:38:52 +0100
Subject: [PATCH] [clang][bytecode] Move a local variable to a later point
We don't need `E` before.
---
clang/lib/AST/ByteCode/Pointer.cpp | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/clang/lib/AST/ByteCode/Pointer.cpp b/clang/lib/AST/ByteCode/Pointer.cpp
index 54484853fcdaea..01e642310aad37 100644
--- a/clang/lib/AST/ByteCode/Pointer.cpp
+++ b/clang/lib/AST/ByteCode/Pointer.cpp
@@ -476,10 +476,10 @@ bool Pointer::pointsToLiteral() const {
if (isZero() || !isBlockPointer())
return false;
- const Expr *E = block()->getDescriptor()->asExpr();
if (block()->isDynamic())
return false;
+ const Expr *E = block()->getDescriptor()->asExpr();
return E && !isa<MaterializeTemporaryExpr, StringLiteral>(E);
}
More information about the cfe-commits
mailing list