CodeQL library for JavaScript
codeql/javascript-all 0.7.5 ( changelog , source )
Search

Member predicate StmtContainer :: getFunctionBoundary

Gets the innermost enclosing function or top-level, possibly this container itself if it is a function or top-level.

To get a strictly enclosing function or top-level, use getEnclosingContainer().getFunctionBoundary().

TypeScript namespace declarations are containers that are not considered function boundaries. In plain JavaScript, all containers are function boundaries.

StmtContainer getFunctionBoundary ( )