mirror of
https://github.com/github/codeql.git
synced 2026-04-25 00:35:20 +02:00
Merge pull request #14430 from RasmusWL/api-graph-import-star
Python: Better allow `import *` to work with API graphs
This commit is contained in:
@@ -2,9 +2,11 @@
|
||||
|
||||
from unknown import * #$ use=moduleImport("unknown")
|
||||
|
||||
# Currently missing, as we do not consider `hello` to be a `LocalSourceNode`, since it has flow
|
||||
# going into it from its corresponding `GlobalSsaVariable`.
|
||||
hello() #$ MISSING: use=moduleImport("unknown").getMember("hello").getReturn()
|
||||
# This used to be missing, as we did not consider `hello` to be a `LocalSourceNode`,
|
||||
# since it has flow going into it from its corresponding `GlobalSsaVariable`.
|
||||
hello() #$ use=moduleImport("unknown").getMember("hello").getReturn()
|
||||
|
||||
print(const_from_unknown) #$ use=moduleImport("unknown").getMember("const_from_unknown")
|
||||
|
||||
# We don't want our analysis to think that either `non_module_member` or `outer_bar` can
|
||||
# come from `from unknown import *`
|
||||
|
||||
Reference in New Issue
Block a user