We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 664dac6 commit 30b7fadCopy full SHA for 30b7fad
python/ql/test/experimental/dataflow/fieldflow/test_dict.py
@@ -45,6 +45,16 @@ def test_dict_update():
45
SINK(d["key"]) # $ flow="SOURCE, l:-1 -> d['key']"
46
SINK(d.get("key")) # $ flow="SOURCE, l:-2 -> d.get(..)"
47
48
+
49
+@expects(2) # $ unresolved_call=expects(..) unresolved_call=expects(..)(..)
50
+def test_dict_update_fresh_key():
51
+ # we had a regression where we did not create a dictionary element content
52
+ # for keys used in "inline update" like this
53
+ d = {}
54
+ d["fresh_key"] = SOURCE
55
+ SINK(d["fresh_key"]) # $ MISSING: flow="SOURCE, l:-1 -> d['fresh_key']"
56
57
58
@expects(3) # $ unresolved_call=expects(..) unresolved_call=expects(..)(..)
59
def test_dict_setdefault():
60
d = {}
0 commit comments