mirror of
https://github.com/github/codeql.git
synced 2026-04-30 11:15:13 +02:00
Python: Add test for inner return
This commit is contained in:
@@ -580,3 +580,12 @@ def test_dynamic_tuple_creation_4():
|
||||
|
||||
SINK(tup[0]) # Flow missing
|
||||
SINK_F(tup[1])
|
||||
|
||||
def return_from_inner_scope(x):
|
||||
try:
|
||||
return x[0]
|
||||
except IndexError:
|
||||
return SOURCE
|
||||
|
||||
def test_return_from_inner_scope():
|
||||
SINK(return_from_inner_scope([]))
|
||||
|
||||
Reference in New Issue
Block a user