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

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

Issue 889573005: dart2js: emit callstubs in new emitter and rename to stubs. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 5 years, 10 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 part of dart2js.js_emitter; 5 part of dart2js.js_emitter;
6 6
7 class ClassEmitter extends CodeEmitterHelper { 7 class ClassEmitter extends CodeEmitterHelper {
8 8
9 ClassStubGenerator get _stubGenerator => 9 ClassStubGenerator get _stubGenerator =>
10 new ClassStubGenerator(compiler, namer, backend); 10 new ClassStubGenerator(compiler, namer, backend);
(...skipping 196 matching lines...) Expand 10 before | Expand all | Expand 10 after
207 emitGetterForCSP(member, field.name, field.accessorName, builder); 207 emitGetterForCSP(member, field.name, field.accessorName, builder);
208 } 208 }
209 if (field.needsUncheckedSetter) { 209 if (field.needsUncheckedSetter) {
210 emitSetterForCSP(member, field.name, field.accessorName, builder); 210 emitSetterForCSP(member, field.name, field.accessorName, builder);
211 } 211 }
212 }); 212 });
213 } 213 }
214 } 214 }
215 215
216 void emitCallStubs(Class cls, ClassBuilder builder) { 216 void emitCallStubs(Class cls, ClassBuilder builder) {
217 for (Method method in cls.callStubs) { 217 for (Method method in cls.stubs) {
218 jsAst.Property property = builder.addProperty(method.name, method.code); 218 jsAst.Property property = builder.addProperty(method.name, method.code);
219 compiler.dumpInfoTask.registerElementAst(method.element, property); 219 compiler.dumpInfoTask.registerElementAst(method.element, property);
220 } 220 }
221 } 221 }
222 222
223 /** 223 /**
224 * Documentation wanted -- johnniwinther 224 * Documentation wanted -- johnniwinther
225 * 225 *
226 * Invariant: [classElement] must be a declaration element. 226 * Invariant: [classElement] must be a declaration element.
227 */ 227 */
(...skipping 360 matching lines...) Expand 10 before | Expand all | Expand 10 after
588 js.number(index)); 588 js.number(index));
589 } 589 }
590 jsAst.Expression convertRtiToRuntimeType = emitter 590 jsAst.Expression convertRtiToRuntimeType = emitter
591 .staticFunctionAccess(backend.findHelper('convertRtiToRuntimeType')); 591 .staticFunctionAccess(backend.findHelper('convertRtiToRuntimeType'));
592 compiler.dumpInfoTask.registerElementAst(element, 592 compiler.dumpInfoTask.registerElementAst(element,
593 builder.addProperty(name, 593 builder.addProperty(name,
594 js('function () { return #(#) }', 594 js('function () { return #(#) }',
595 [convertRtiToRuntimeType, computeTypeVariable]))); 595 [convertRtiToRuntimeType, computeTypeVariable])));
596 } 596 }
597 } 597 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698