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

Unified Diff: pkg/compiler/lib/src/js_emitter/old_emitter/class_emitter.dart

Issue 850343005: Revert r42934. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 5 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 | « no previous file | pkg/compiler/lib/src/js_emitter/old_emitter/emitter.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/compiler/lib/src/js_emitter/old_emitter/class_emitter.dart
===================================================================
--- pkg/compiler/lib/src/js_emitter/old_emitter/class_emitter.dart (revision 42938)
+++ pkg/compiler/lib/src/js_emitter/old_emitter/class_emitter.dart (working copy)
@@ -11,11 +11,12 @@
/**
* Documentation wanted -- johnniwinther
+ *
+ * Invariant: [classElement] must be a declaration element.
*/
- void emitClass(Class cls,
- ClassBuilder enclosingBuilder,
- Map<String, jsAst.Expression> additionalProperties) {
- ClassElement classElement = cls.element;
+ void generateClass(ClassElement classElement,
+ ClassBuilder properties,
+ Map<String, jsAst.Expression> additionalProperties) {
final onlyForRti =
emitter.typeTestRegistry.rtiNeededClasses.contains(classElement);
@@ -31,9 +32,8 @@
superName = namer.getNameOfClass(superclass);
}
- if (cls.isMixinApplication) {
- MixinApplication mixinApplication = cls;
- String mixinName = mixinApplication.mixinClass.name;
+ if (classElement.isMixinApplication) {
+ String mixinName = namer.getNameOfClass(computeMixinClass(classElement));
superName = '$superName+$mixinName';
emitter.needsMixinSupport = true;
}
@@ -60,7 +60,7 @@
emitTypeVariableReaders(classElement, builder);
emitClassBuilderWithReflectionData(
- className, classElement, builder, enclosingBuilder);
+ className, classElement, builder, properties);
}
void emitClassConstructor(ClassElement classElement,
« no previous file with comments | « no previous file | pkg/compiler/lib/src/js_emitter/old_emitter/emitter.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698