Skip to content

Commit e98d1df

Browse files
committed
add dataflow support
1 parent a8973c1 commit e98d1df

File tree

2 files changed

+4
-0
lines changed

2 files changed

+4
-0
lines changed

javascript/ql/lib/semmle/javascript/dataflow/DataFlow.qll

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1580,6 +1580,8 @@ module DataFlow {
15801580
or
15811581
predExpr = succExpr.(TypeAssertion).getExpression()
15821582
or
1583+
predExpr = succExpr.(SatisfiesExpr).getExpression()
1584+
or
15831585
predExpr = succExpr.(NonNullAssertion).getExpression()
15841586
or
15851587
predExpr = succExpr.(ExpressionWithTypeArguments).getExpression()

javascript/ql/test/library-tests/DataFlow/tests.expected

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -998,6 +998,7 @@ flowStep
998998
| tst2.ts:13:26:13:29 | List | tst2.ts:13:26:13:37 | List<string> |
999999
| tst2.ts:13:39:13:38 | args | tst2.ts:13:39:13:38 | args |
10001000
| tst2.ts:13:39:13:38 | args | tst2.ts:13:39:13:38 | args |
1001+
| tst2.ts:15:11:15:13 | A.x | tst2.ts:15:11:15:30 | A.x satisfies number |
10011002
| tst.js:1:1:1:1 | x | tst.js:3:5:3:5 | x |
10021003
| tst.js:1:10:1:11 | fs | tst.js:1:10:1:11 | fs |
10031004
| tst.js:1:10:1:11 | fs | tst.js:7:1:7:2 | fs |
@@ -1184,6 +1185,7 @@ getImmediatePredecessor
11841185
| tst2.ts:13:26:13:29 | List | tst2.ts:13:26:13:37 | List<string> |
11851186
| tst2.ts:13:39:13:38 | args | tst2.ts:13:39:13:38 | args |
11861187
| tst2.ts:13:39:13:38 | args | tst2.ts:13:39:13:38 | args |
1188+
| tst2.ts:15:11:15:13 | A.x | tst2.ts:15:11:15:30 | A.x satisfies number |
11871189
| tst.js:1:10:1:11 | fs | tst.js:1:10:1:11 | fs |
11881190
| tst.js:1:10:1:11 | fs | tst.js:7:1:7:2 | fs |
11891191
| tst.js:1:10:1:11 | fs | tst.js:22:24:22:25 | fs |

0 commit comments

Comments
 (0)