Module Enclosing

INTERNAL: Do not use.

Provides efficient cached predicates for finding enclosing statements and callables.

There are a number of difficulties. There can be expressions without enclosing statements (for example initialisers for fields and constructors) or enclosing callables (even if we consider constructor initialisers to be enclosed by constructors, field initialisers don’t have callables).

The only cases where a Stmt has an Expr parent are delegate and lambda expressions, which are both callable.

Import path

semmle.code.csharp.Enclosing

Imports

Stmt

Provides all statement classes.

Modules

Internal

INTERNAL: Do not use.