C#: Fix expanded assignment lookup in finally blocks for CFG

This commit is contained in:
Tamas Vajk
2021-01-07 12:15:21 +01:00
parent 5803a449be
commit 05c858ec2c
6 changed files with 57 additions and 3 deletions

View File

@@ -1302,7 +1302,7 @@ module Statements {
/** Gets a child of `cfe` that is in CFG scope `scope`. */
pragma[noinline]
private ControlFlowElement getAChildInScope(ControlFlowElement cfe, Callable scope) {
result = cfe.getAChild() and
result = [cfe.getAChild(), cfe.(AssignOperation).getExpandedAssignment()] and
scope = result.getEnclosingCallable()
}