anchor.diff:      // Sort errors.
       errors.sort((AnalysisError e1, AnalysisError e2) => e1.offset - e2.offset);
   
  -    Source source = target;
  -    String contents = context.getContents(source).data;
  -    Scanner scanner = new Scanner(source, new CharSequenceReader(contents),
  -        AnalysisErrorListener.NULL_LISTENER);
  -
  -    // Scan.
  -    Token token = scanner.tokenize();
  -    LineInfo lineInfo = new LineInfo(scanner.lineStarts);
  +    CompilationUnit cu = getRequiredInput(PARSED_UNIT_INPUT);
  +    Token token = cu.beginToken;
  +    LineInfo lineInfo = getRequiredInput(LINE_INFO_INPUT);
   
       int errorIndex = 0;
   
  
positive.code:   static final TaskDescriptor DESCRIPTOR = new TaskDescriptor('DartErrorsTask',
        createTask, buildInputs, <ResultDescriptor>[DART_ERRORS]);
  
    // Prefix for comments ignoring error codes.
    static const String _normalizedIgnorePrefix = '//#ignore:';
  
  
negative.code:   static Map<String, TaskInput> buildInputs(AnalysisTarget target) {
      Source source = target;
      Map<String, TaskInput> inputs = <String, TaskInput>{};
      inputs[LINE_INFO_INPUT] = LINE_INFO.of(source);
      inputs[PARSED_UNIT_INPUT] = PARSED_UNIT.of(source);
      EnginePlugin enginePlugin = AnalysisEngine.instance.enginePlugin;
      // for Source
      for (ResultDescriptor result in enginePlugin.dartErrorsForSource) {
  