File tree Expand file tree Collapse file tree 1 file changed +6
-0
lines changed
python/ql/lib/semmle/python Expand file tree Collapse file tree 1 file changed +6
-0
lines changed Original file line number Diff line number Diff line change @@ -754,15 +754,21 @@ module API {
754
754
dict .getItem ( _) = item
755
755
|
756
756
// from `x` to `{ "key": x }`
757
+ // TODO: once convenient, this should be done at a higher level than the AST,
758
+ // at least at the CFG layer, to take splitting into account.
757
759
rhs .( DataFlow:: ExprNode ) .getNode ( ) .getNode ( ) = item .getValue ( ) and
758
760
lbl = Label:: subscript ( )
759
761
or
760
762
// from `"key"` to `{ "key": x }`
763
+ // TODO: once convenient, this should be done at a higher level than the AST,
764
+ // at least at the CFG layer, to take splitting into account.
761
765
rhs .( DataFlow:: ExprNode ) .getNode ( ) .getNode ( ) = item .getKey ( ) and
762
766
lbl = Label:: index ( )
763
767
)
764
768
or
765
769
// list literals, from `x` to `[x]`
770
+ // TODO: once convenient, this should be done at a higher level than the AST,
771
+ // at least at the CFG layer, to take splitting into account.
766
772
exists ( PY:: List list | list = pred .( DataFlow:: ExprNode ) .getNode ( ) .getNode ( ) |
767
773
rhs .( DataFlow:: ExprNode ) .getNode ( ) .getNode ( ) = list .getAnElt ( ) and
768
774
lbl = Label:: subscript ( )
You can’t perform that action at this time.
0 commit comments