Skip to content

Commit d56f763

Browse files
committed
PR feedback
1 parent d69c344 commit d56f763

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

llvm/lib/CodeGen/WindowsSecureHotPatching.cpp

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -451,8 +451,7 @@ static bool searchConstantExprForGlobalVariables(
451451

452452
SmallVector<Value *, 8> ReplacedOperands;
453453

454-
if (V->getValueID() == Value::GlobalVariableVal) {
455-
GlobalVariable *GV = cast<GlobalVariable>(V);
454+
if (GlobalVariable *GV = dyn_cast<GlobalVariable>(V)) {
456455
if (globalVariableNeedsRedirect(GV)) {
457456
GVLoadMap[GV] = nullptr;
458457
return true;

0 commit comments

Comments
 (0)