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

Unified Diff: pkg/analyzer/lib/src/dart/constant/evaluation.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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | pkg/analyzer/lib/src/dart/constant/utilities.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/analyzer/lib/src/dart/constant/evaluation.dart
diff --git a/pkg/analyzer/lib/src/dart/constant/evaluation.dart b/pkg/analyzer/lib/src/dart/constant/evaluation.dart
index 0c8288a4850e3c770b9f97be5a70193335f336ea..57eee8973823954d54ef94305c1c0136612c826c 100644
--- a/pkg/analyzer/lib/src/dart/constant/evaluation.dart
+++ b/pkg/analyzer/lib/src/dart/constant/evaluation.dart
@@ -23,7 +23,6 @@ import 'package:analyzer/src/generated/engine.dart'
import 'package:analyzer/src/generated/error.dart';
import 'package:analyzer/src/generated/java_core.dart';
import 'package:analyzer/src/generated/resolver.dart' show TypeProvider;
-import 'package:analyzer/src/generated/source.dart' show Source;
import 'package:analyzer/src/generated/type_system.dart'
show TypeSystem, TypeSystemImpl;
import 'package:analyzer/src/generated/utilities_collection.dart';
@@ -930,15 +929,13 @@ class ConstantValueComputer {
*/
final ConstantEvaluationEngine evaluationEngine;
- final AnalysisContext _context;
-
/**
* Initialize a newly created constant value computer. The [typeProvider] is
* the type provider used to access known types. The [declaredVariables] is
* the set of variables declared on the command line using '-D'.
*/
- ConstantValueComputer(this._context, TypeProvider typeProvider,
- DeclaredVariables declaredVariables,
+ ConstantValueComputer(
+ TypeProvider typeProvider, DeclaredVariables declaredVariables,
[ConstantEvaluationValidator validator, TypeSystem typeSystem])
: evaluationEngine = new ConstantEvaluationEngine(
typeProvider, declaredVariables,
@@ -948,9 +945,8 @@ class ConstantValueComputer {
* Add the constants in the given compilation [unit] to the list of constants
* whose value needs to be computed.
*/
- void add(CompilationUnit unit, Source source, Source librarySource) {
- ConstantFinder constantFinder =
- new ConstantFinder(_context, source, librarySource);
+ void add(CompilationUnit unit) {
+ ConstantFinder constantFinder = new ConstantFinder();
unit.accept(constantFinder);
_constantsToCompute.addAll(constantFinder.constantsToCompute);
}
« no previous file with comments | « no previous file | pkg/analyzer/lib/src/dart/constant/utilities.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698