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

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

Issue 2608143002: Refactor BackendHelpers to make 'find' methods private. (Closed)
Patch Set: Updated cf. comments. Created 3 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « pkg/compiler/lib/src/js_backend/checked_mode_helpers.dart ('k') | pkg/compiler/lib/src/native/enqueue.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/compiler/lib/src/js_backend/constant_system_javascript.dart
diff --git a/pkg/compiler/lib/src/js_backend/constant_system_javascript.dart b/pkg/compiler/lib/src/js_backend/constant_system_javascript.dart
index ee445b3ecef129b338e0bc803d2f1d173747f8a1..cbc01569522cca20cd0af41b98b3c8437c475484 100644
--- a/pkg/compiler/lib/src/js_backend/constant_system_javascript.dart
+++ b/pkg/compiler/lib/src/js_backend/constant_system_javascript.dart
@@ -370,12 +370,11 @@ class JavaScriptConstantSystem extends ConstantSystem {
keysType = commonElements.listType(sourceType.typeArguments.first);
}
ListConstantValue keysList = new ListConstantValue(keysType, keys);
- String className = onlyStringKeys
+ ClassElement classElement = onlyStringKeys
? (hasProtoKey
- ? JavaScriptMapConstant.DART_PROTO_CLASS
- : JavaScriptMapConstant.DART_STRING_CLASS)
- : JavaScriptMapConstant.DART_GENERAL_CLASS;
- ClassElement classElement = backend.helpers.jsHelperLibrary.find(className);
+ ? backend.helpers.constantProtoMapClass
+ : backend.helpers.constantStringMapClass)
+ : backend.helpers.generalConstantMapClass;
classElement.ensureResolved(compiler.resolution);
List<DartType> typeArgument = sourceType.typeArguments;
InterfaceType type;
« no previous file with comments | « pkg/compiler/lib/src/js_backend/checked_mode_helpers.dart ('k') | pkg/compiler/lib/src/native/enqueue.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698