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

Side by Side Diff: pkg/analyzer/lib/src/task/dart.dart

Issue 2154083002: Remove ConstantFinder constructor parameters. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 4 years, 5 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) 2015, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2015, 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.task.dart; 5 library analyzer.src.task.dart;
6 6
7 import 'dart:collection'; 7 import 'dart:collection';
8 8
9 import 'package:analyzer/dart/ast/ast.dart'; 9 import 'package:analyzer/dart/ast/ast.dart';
10 import 'package:analyzer/dart/ast/token.dart'; 10 import 'package:analyzer/dart/ast/token.dart';
(...skipping 1084 matching lines...) Expand 10 before | Expand all | Expand 10 after
1095 if (element == null) { 1095 if (element == null) {
1096 CompilationUnitBuilder builder = new CompilationUnitBuilder(); 1096 CompilationUnitBuilder builder = new CompilationUnitBuilder();
1097 element = builder.buildCompilationUnit( 1097 element = builder.buildCompilationUnit(
1098 source, unit, librarySpecificUnit.library); 1098 source, unit, librarySpecificUnit.library);
1099 } else { 1099 } else {
1100 new DeclarationResolver().resolve(unit, element); 1100 new DeclarationResolver().resolve(unit, element);
1101 } 1101 }
1102 // 1102 //
1103 // Prepare constants. 1103 // Prepare constants.
1104 // 1104 //
1105 ConstantFinder constantFinder = 1105 ConstantFinder constantFinder = new ConstantFinder();
1106 new ConstantFinder(context, source, librarySpecificUnit.library);
1107 unit.accept(constantFinder); 1106 unit.accept(constantFinder);
1108 List<ConstantEvaluationTarget> constants = 1107 List<ConstantEvaluationTarget> constants =
1109 new List<ConstantEvaluationTarget>.from( 1108 new List<ConstantEvaluationTarget>.from(
1110 constantFinder.constantsToCompute); 1109 constantFinder.constantsToCompute);
1111 // 1110 //
1112 // Record outputs. 1111 // Record outputs.
1113 // 1112 //
1114 outputs[COMPILATION_UNIT_CONSTANTS] = constants; 1113 outputs[COMPILATION_UNIT_CONSTANTS] = constants;
1115 outputs[COMPILATION_UNIT_ELEMENT] = element; 1114 outputs[COMPILATION_UNIT_ELEMENT] = element;
1116 outputs[RESOLVED_UNIT1] = unit; 1115 outputs[RESOLVED_UNIT1] = unit;
(...skipping 5354 matching lines...) Expand 10 before | Expand all | Expand 10 after
6471 6470
6472 @override 6471 @override
6473 bool moveNext() { 6472 bool moveNext() {
6474 if (_newSources.isEmpty) { 6473 if (_newSources.isEmpty) {
6475 return false; 6474 return false;
6476 } 6475 }
6477 currentTarget = _newSources.removeLast(); 6476 currentTarget = _newSources.removeLast();
6478 return true; 6477 return true;
6479 } 6478 }
6480 } 6479 }
OLDNEW
« no previous file with comments | « pkg/analyzer/lib/src/generated/incremental_resolver.dart ('k') | pkg/analyzer/test/src/dart/constant/evaluation_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698