visitCompilationUnit method

  1. @override
bool visitCompilationUnit (CompilationUnit node)
override

Implementation

@override
bool visitCompilationUnit(CompilationUnit node) {
  if (identical(node.scriptTag, _oldNode)) {
    node.scriptTag = _newNode as ScriptTag;
    return true;
  } else if (_replaceInList(node.directives)) {
    return true;
  } else if (_replaceInList(node.declarations)) {
    return true;
  }
  return visitNode(node);
}