CodeQL library for Go
codeql/go-all 2.1.3-dev (changelog, source)
Search

Member predicate AstNode::getEnclosingFunction

Gets the innermost function definition to which this AST node belongs, if any.

FuncDef getEnclosingFunction()