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

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

Issue 2229603003: Extract unresolved AST parsing (PARSED_UNIT1) from full parsing, which includes UriBasedDirective(s… (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Update task graph. Created 4 years, 4 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
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 analyzer.src.generated.incremental_resolver; 5 library analyzer.src.generated.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 'package:analyzer/dart/ast/ast.dart'; 10 import 'package:analyzer/dart/ast/ast.dart';
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after
111 isByTask(LibraryErrorsReadyTask.DESCRIPTOR) || 111 isByTask(LibraryErrorsReadyTask.DESCRIPTOR) ||
112 isByTask(LibraryUnitErrorsTask.DESCRIPTOR) || 112 isByTask(LibraryUnitErrorsTask.DESCRIPTOR) ||
113 isByTask(ParseDartTask.DESCRIPTOR) || 113 isByTask(ParseDartTask.DESCRIPTOR) ||
114 isByTask(PartiallyResolveUnitReferencesTask.DESCRIPTOR) || 114 isByTask(PartiallyResolveUnitReferencesTask.DESCRIPTOR) ||
115 isByTask(PropagateVariableTypesInLibraryClosureTask.DESCRIPTOR) || 115 isByTask(PropagateVariableTypesInLibraryClosureTask.DESCRIPTOR) ||
116 isByTask(PropagateVariableTypesInLibraryTask.DESCRIPTOR) || 116 isByTask(PropagateVariableTypesInLibraryTask.DESCRIPTOR) ||
117 isByTask(PropagateVariableTypesInUnitTask.DESCRIPTOR) || 117 isByTask(PropagateVariableTypesInUnitTask.DESCRIPTOR) ||
118 isByTask(PropagateVariableTypeTask.DESCRIPTOR) || 118 isByTask(PropagateVariableTypeTask.DESCRIPTOR) ||
119 isByTask(ScanDartTask.DESCRIPTOR) || 119 isByTask(ScanDartTask.DESCRIPTOR) ||
120 isByTask(ResolveConstantExpressionTask.DESCRIPTOR) || 120 isByTask(ResolveConstantExpressionTask.DESCRIPTOR) ||
121 isByTask(ResolveDirectivesTask.DESCRIPTOR) ||
121 isByTask(ResolveDirectiveElementsTask.DESCRIPTOR) || 122 isByTask(ResolveDirectiveElementsTask.DESCRIPTOR) ||
122 isByTask(ResolveInstanceFieldsInUnitTask.DESCRIPTOR) || 123 isByTask(ResolveInstanceFieldsInUnitTask.DESCRIPTOR) ||
123 isByTask(ResolveLibraryReferencesTask.DESCRIPTOR) || 124 isByTask(ResolveLibraryReferencesTask.DESCRIPTOR) ||
124 isByTask(ResolveLibraryTask.DESCRIPTOR) || 125 isByTask(ResolveLibraryTask.DESCRIPTOR) ||
125 isByTask(ResolveLibraryTypeNamesTask.DESCRIPTOR) || 126 isByTask(ResolveLibraryTypeNamesTask.DESCRIPTOR) ||
126 isByTask(ResolveTopLevelLibraryTypeBoundsTask.DESCRIPTOR) || 127 isByTask(ResolveTopLevelLibraryTypeBoundsTask.DESCRIPTOR) ||
127 isByTask(ResolveTopLevelUnitTypeBoundsTask.DESCRIPTOR) || 128 isByTask(ResolveTopLevelUnitTypeBoundsTask.DESCRIPTOR) ||
128 isByTask(ResolveUnitTask.DESCRIPTOR) || 129 isByTask(ResolveUnitTask.DESCRIPTOR) ||
129 isByTask(ResolveUnitTypeNamesTask.DESCRIPTOR) || 130 isByTask(ResolveUnitTypeNamesTask.DESCRIPTOR) ||
130 isByTask(ResolveVariableReferencesTask.DESCRIPTOR) || 131 isByTask(ResolveVariableReferencesTask.DESCRIPTOR) ||
(...skipping 738 matching lines...) Expand 10 before | Expand all | Expand 10 after
869 token = token.next; 870 token = token.next;
870 } 871 }
871 } 872 }
872 873
873 void _updateEntry() { 874 void _updateEntry() {
874 // scan results 875 // scan results
875 _sourceEntry.setValueIncremental(SCAN_ERRORS, _newScanErrors, true); 876 _sourceEntry.setValueIncremental(SCAN_ERRORS, _newScanErrors, true);
876 _sourceEntry.setValueIncremental(LINE_INFO, _newLineInfo, false); 877 _sourceEntry.setValueIncremental(LINE_INFO, _newLineInfo, false);
877 // parse results 878 // parse results
878 _sourceEntry.setValueIncremental(PARSE_ERRORS, _newParseErrors, true); 879 _sourceEntry.setValueIncremental(PARSE_ERRORS, _newParseErrors, true);
880 _sourceEntry.setValueIncremental(PARSED_UNIT1, _oldUnit, false);
879 _sourceEntry.setValueIncremental(PARSED_UNIT, _oldUnit, false); 881 _sourceEntry.setValueIncremental(PARSED_UNIT, _oldUnit, false);
882 _sourceEntry.setValueIncremental(RESOLVE_DIRECTIVES_ERRORS, _newParseErrors, true);
880 // referenced names 883 // referenced names
881 ReferencedNames referencedNames = new ReferencedNames(_unitSource); 884 ReferencedNames referencedNames = new ReferencedNames(_unitSource);
882 new ReferencedNamesBuilder(referencedNames).build(_oldUnit); 885 new ReferencedNamesBuilder(referencedNames).build(_oldUnit);
883 _sourceEntry.setValueIncremental(REFERENCED_NAMES, referencedNames, false); 886 _sourceEntry.setValueIncremental(REFERENCED_NAMES, referencedNames, false);
884 } 887 }
885 888
886 /** 889 /**
887 * Checks if [token] has a balanced number of open and closed curly brackets. 890 * Checks if [token] has a balanced number of open and closed curly brackets.
888 */ 891 */
889 static bool _areCurlyBracketsBalanced(Token token) { 892 static bool _areCurlyBracketsBalanced(Token token) {
(...skipping 424 matching lines...) Expand 10 before | Expand all | Expand 10 after
1314 @override 1317 @override
1315 String toString() => name; 1318 String toString() => name;
1316 } 1319 }
1317 1320
1318 class _TokenPair { 1321 class _TokenPair {
1319 final _TokenDifferenceKind kind; 1322 final _TokenDifferenceKind kind;
1320 final Token oldToken; 1323 final Token oldToken;
1321 final Token newToken; 1324 final Token newToken;
1322 _TokenPair(this.kind, this.oldToken, this.newToken); 1325 _TokenPair(this.kind, this.oldToken, this.newToken);
1323 } 1326 }
OLDNEW
« no previous file with comments | « pkg/analyzer/lib/src/context/context.dart ('k') | pkg/analyzer/lib/src/plugin/engine_plugin.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698