Simplify comparison of DataFlow::Node and IR::Instruction

Co-authored-by: Chris Smowton <smowton@github.com>
This commit is contained in:
Owen Mansel-Chan
2022-02-03 14:37:01 +00:00
committed by Owen Mansel-Chan
parent 9b61ed9578
commit 98c60f31a6

View File

@@ -37,7 +37,7 @@ class NilTestGuard extends DataFlow::BarrierGuard, DataFlow::EqualityTestNode {
DataFlow::ExprNode getNilFromLocalVariable() {
exists(SsaVariable ssa, Write w |
w.definesSsaVariable(ssa, Builtin::nil().getARead()) and
result.getExpr() = ssa.getAUse().(IR::EvalInstruction).getExpr()
result.asInstruction() = ssa.getAUse()
)
}