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

Unified Diff: pkg/compiler/lib/src/js_backend/type_variable_handler.dart

Issue 2814453005: Merge CommonElements and BackendHelpers! (Closed)
Patch Set: comments and re-merge, take two Created 3 years, 8 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
Index: pkg/compiler/lib/src/js_backend/type_variable_handler.dart
diff --git a/pkg/compiler/lib/src/js_backend/type_variable_handler.dart b/pkg/compiler/lib/src/js_backend/type_variable_handler.dart
index 617f8f5dd0ed9e3d788b4bef19b5468317d58551..e66d79acc61cbe9dbab0fc8cae69512e1f4177a6 100644
--- a/pkg/compiler/lib/src/js_backend/type_variable_handler.dart
+++ b/pkg/compiler/lib/src/js_backend/type_variable_handler.dart
@@ -15,7 +15,6 @@ import '../universe/use.dart' show ConstantUse;
import '../universe/world_impact.dart';
import 'backend.dart';
import 'backend_usage.dart' show BackendUsageBuilder;
-import 'backend_helpers.dart';
import 'backend_impact.dart';
import 'mirrors_data.dart';
@@ -59,7 +58,7 @@ class TypeVariableResolutionAnalysis {
class TypeVariableCodegenAnalysis {
final ElementEnvironment _elementEnvironment;
final JavaScriptBackend _backend;
- final BackendHelpers _helpers;
+ final CommonElements _commonElements;
final MirrorsData _mirrorsData;
/**
@@ -81,7 +80,7 @@ class TypeVariableCodegenAnalysis {
new StagedWorldImpactBuilder();
TypeVariableCodegenAnalysis(this._elementEnvironment, this._backend,
- this._helpers, this._mirrorsData);
+ this._commonElements, this._mirrorsData);
CodeEmitterTask get _task => _backend.emitter;
MetadataCollector get _metadataCollector => _task.metadataCollector;
@@ -112,10 +111,10 @@ class TypeVariableCodegenAnalysis {
_elementEnvironment.getTypeVariableBound(typeVariableElement));
ConstantValue boundValue = new SyntheticConstantValue(
SyntheticConstantKind.TYPEVARIABLE_REFERENCE, boundIndex);
- ClassEntity typeVariableClass = _helpers.typeVariableClass;
+ ClassEntity typeVariableClass = _commonElements.typeVariableClass;
ConstantExpression constant = new ConstructedConstantExpression(
_elementEnvironment.getThisType(typeVariableClass),
- _helpers.typeVariableConstructor,
+ _commonElements.typeVariableConstructor,
const CallStructure.unnamed(3), [
new TypeConstantExpression(
_elementEnvironment.getRawType(cls), cls.name),
« no previous file with comments | « pkg/compiler/lib/src/js_backend/runtime_types.dart ('k') | pkg/compiler/lib/src/js_emitter/class_stub_generator.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698