mirror of
https://github.com/github/codeql.git
synced 2026-05-04 05:05:12 +02:00
Python: Add flow-step for arg[1] to dict.setdefault
This commit is contained in:
@@ -49,7 +49,7 @@ def test_dict_update():
|
||||
def test_setdefault():
|
||||
d = {}
|
||||
x = d.setdefault("key", SOURCE)
|
||||
SINK(x) # $ MISSING: flow="SOURCE, l:-1 -> d.setdefault(..)"
|
||||
SINK(x) # $ flow="SOURCE, l:-1 -> x"
|
||||
SINK(d["key"]) # $ flow="SOURCE, l:-2 -> d['key']"
|
||||
SINK(d.setdefault("key", NONSOURCE)) # $ flow="SOURCE, l:-3 -> d.setdefault(..)"
|
||||
|
||||
|
||||
Reference in New Issue
Block a user