AstNodeExt extension

Extension for the AstNode class from the analyzer package. Adds helper methods for working with AST nodes.

on
  • AstNode

Methods

getNodeOfExactType<T>() → T?

Available on AstNode, provided by the AstNodeExt extension

Returns a node of type T if the current node is an instance of that type. If the node does not match the type T, returns null.