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

Unified Diff: dart/sdk/lib/_internal/compiler/implementation/js_backend/namer.dart

Issue 22835003: Put constants in 'C', not '$'. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « dart/sdk/lib/_internal/compiler/implementation/js_backend/emitter.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: dart/sdk/lib/_internal/compiler/implementation/js_backend/namer.dart
diff --git a/dart/sdk/lib/_internal/compiler/implementation/js_backend/namer.dart b/dart/sdk/lib/_internal/compiler/implementation/js_backend/namer.dart
index 796718a952e1332d816ccf878f07482f20233575..cb2508c789d51231fcb23df91336c3a25bb82963 100644
--- a/dart/sdk/lib/_internal/compiler/implementation/js_backend/namer.dart
+++ b/dart/sdk/lib/_internal/compiler/implementation/js_backend/namer.dart
@@ -145,7 +145,10 @@ class Namer implements ClosureNamer {
// These keywords trigger the loading of the java-plugin. For the
// next-generation plugin, this results in starting a new Java process.
"java", "Packages", "netscape", "sun", "JavaObject", "JavaClass",
- "JavaArray", "JavaMember"
+ "JavaArray", "JavaMember",
+
+ // Global object for constants.
+ "C",
];
Set<String> _jsReserved = null;
@@ -775,6 +778,8 @@ class Namer implements ClosureNamer {
return "$CURRENT_ISOLATE.${getStaticClosureName(element)}";
}
+ String globalObjectForConstant(Constant constant) => 'C';
+
String operatorIsPrefix() => r'$is';
String operatorAsPrefix() => r'$as';
« no previous file with comments | « dart/sdk/lib/_internal/compiler/implementation/js_backend/emitter.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698