Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(289)

Side by Side Diff: pkg/analyzer/lib/src/generated/incremental_resolver.dart

Issue 844063002: Update errors offsets during incremental comment resolution. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 5 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | pkg/analyzer/test/generated/incremental_resolver_test.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 library engine.incremental_resolver; 5 library engine.incremental_resolver;
6 6
7 import 'dart:collection'; 7 import 'dart:collection';
8 import 'dart:math' as math; 8 import 'dart:math' as math;
9 9
10 import 'ast.dart'; 10 import 'ast.dart';
(...skipping 1371 matching lines...) Expand 10 before | Expand all | Expand 10 after
1382 _setPrecedingComments(oldToken, newComment.tokens.first); 1382 _setPrecedingComments(oldToken, newComment.tokens.first);
1383 // replace node 1383 // replace node
1384 NodeReplacer.replace(oldComment, newComment); 1384 NodeReplacer.replace(oldComment, newComment);
1385 // update elements 1385 // update elements
1386 IncrementalResolver incrementalResolver = new IncrementalResolver( 1386 IncrementalResolver incrementalResolver = new IncrementalResolver(
1387 _unitElement, 1387 _unitElement,
1388 _updateOffset, 1388 _updateOffset,
1389 _updateEndOld, 1389 _updateEndOld,
1390 _updateEndNew); 1390 _updateEndNew);
1391 incrementalResolver._updateElementNameOffsets(); 1391 incrementalResolver._updateElementNameOffsets();
1392 incrementalResolver._shiftEntryErrors();
1392 _updateEntry(); 1393 _updateEntry();
1393 // resolve references in the comment 1394 // resolve references in the comment
1394 incrementalResolver._resolveReferences(newComment); 1395 incrementalResolver._resolveReferences(newComment);
1395 // OK 1396 // OK
1396 return true; 1397 return true;
1397 } 1398 }
1398 1399
1399 Token _scan(String code) { 1400 Token _scan(String code) {
1400 RecordingErrorListener errorListener = new RecordingErrorListener(); 1401 RecordingErrorListener errorListener = new RecordingErrorListener();
1401 CharSequenceReader reader = new CharSequenceReader(code); 1402 CharSequenceReader reader = new CharSequenceReader(code);
(...skipping 424 matching lines...) Expand 10 before | Expand all | Expand 10 after
1826 String toString() => name; 1827 String toString() => name;
1827 } 1828 }
1828 1829
1829 1830
1830 class _TokenPair { 1831 class _TokenPair {
1831 final _TokenDifferenceKind kind; 1832 final _TokenDifferenceKind kind;
1832 final Token oldToken; 1833 final Token oldToken;
1833 final Token newToken; 1834 final Token newToken;
1834 _TokenPair(this.kind, this.oldToken, this.newToken); 1835 _TokenPair(this.kind, this.oldToken, this.newToken);
1835 } 1836 }
OLDNEW
« no previous file with comments | « no previous file | pkg/analyzer/test/generated/incremental_resolver_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698