Scope.getEnclosingFunction

Find the lexically enclosing function (if any).

This function skips through generated FuncDeclarations, e.g. rewritten foreach bodies.

struct Scope
extern (D) inout
getEnclosingFunction
()

Return Value

Type: inout(FuncDeclaration)

the function or null

Meta