CodeQL library for Python
codeql/python-all 2.0.1-dev (changelog, source)
Search

Member predicate Scope::isTopLevel

Holds if this a top-level (non-nested) class or function

predicate isTopLevel()