matches method

bool matches(
  1. ParseTree tree
)

Determine whether or not a parse tree matches this tree pattern.

@param tree The parse tree to match against this tree pattern. @return true if tree is a match for the current tree pattern; otherwise, false.

Implementation

bool matches(ParseTree tree) {
  return matcher.match(tree, pattern: this).succeeded;
}