Files
codeql/python/ql/test/library-tests/PointsTo/new/NameSpace.ql
Taus Brock-Nannestad f07a7bf8cf Python: Autoformat everything using qlformat.
Will need subsequent PRs fixing up test failures (due to deprecated
methods moving around), but other than that everything should be
straight-forward.
2020-07-07 15:43:52 +02:00

19 lines
400 B
Plaintext

import python
import Util
from Scope s, string name, Object val
where
name != "__name__" and
(
exists(ModuleObject m |
m.getModule() = s and
m.attributeRefersTo(name, val, _)
)
or
exists(ClassObject cls |
cls.getPyClass() = s and
cls.declaredAttribute(name) = val
)
)
select locate(s.getLocation(), "abcdghijklopqrs"), s.toString(), name, repr(val)