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

Side by Side Diff: sdk/lib/_internal/compiler/implementation/ir/ir_nodes.dart

Issue 349923004: Add support for superSend to the new IR and dart backend. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 years, 6 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 // IrNodes are kept in a separate library to have precise control over their 5 // IrNodes are kept in a separate library to have precise control over their
6 // dependencies on other parts of the system. 6 // dependencies on other parts of the system.
7 library dart2js.ir_nodes; 7 library dart2js.ir_nodes;
8 8
9 import '../dart2jslib.dart' as dart2js show Constant, ConstructedConstant; 9 import '../dart2jslib.dart' as dart2js show Constant, ConstructedConstant;
10 import '../elements/elements.dart' 10 import '../elements/elements.dart'
(...skipping 297 matching lines...) Expand 10 before | Expand all | Expand 10 after
308 } 308 }
309 309
310 class This extends Primitive { 310 class This extends Primitive {
311 This(); 311 This();
312 312
313 dart2js.Constant get constant => null; 313 dart2js.Constant get constant => null;
314 314
315 accept(Visitor visitor) => visitor.visitThis(this); 315 accept(Visitor visitor) => visitor.visitThis(this);
316 } 316 }
317 317
318 class Super extends Primitive {
asgerf 2014/06/23 10:55:17 Again, I think it's better to have InvokeSuperMeth
sigurdm 2014/06/24 09:23:08 Done.
319 Super();
320
321 dart2js.Constant get constant => null;
322
323 accept(Visitor visitor) => visitor.visitSuper(this);
324 }
325
318 class LiteralList extends Primitive { 326 class LiteralList extends Primitive {
319 /// The List type being created; this is not the type argument. 327 /// The List type being created; this is not the type argument.
320 final GenericType type; 328 final GenericType type;
321 final List<Reference> values; 329 final List<Reference> values;
322 330
323 /// Set to null if this is not a const literal list. 331 /// Set to null if this is not a const literal list.
324 final dart2js.Constant constant; 332 final dart2js.Constant constant;
325 333
326 LiteralList(this.type, List<Primitive> values, [this.constant]) 334 LiteralList(this.type, List<Primitive> values, [this.constant])
327 : this.values = _referenceList(values); 335 : this.values = _referenceList(values);
(...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after
408 T visitInvokeMethod(InvokeMethod node) => visitExpression(node); 416 T visitInvokeMethod(InvokeMethod node) => visitExpression(node);
409 T visitInvokeConstructor(InvokeConstructor node) => visitExpression(node); 417 T visitInvokeConstructor(InvokeConstructor node) => visitExpression(node);
410 T visitConcatenateStrings(ConcatenateStrings node) => visitExpression(node); 418 T visitConcatenateStrings(ConcatenateStrings node) => visitExpression(node);
411 T visitBranch(Branch node) => visitExpression(node); 419 T visitBranch(Branch node) => visitExpression(node);
412 420
413 // Definitions. 421 // Definitions.
414 T visitLiteralList(LiteralList node) => visitPrimitive(node); 422 T visitLiteralList(LiteralList node) => visitPrimitive(node);
415 T visitLiteralMap(LiteralMap node) => visitPrimitive(node); 423 T visitLiteralMap(LiteralMap node) => visitPrimitive(node);
416 T visitConstant(Constant node) => visitPrimitive(node); 424 T visitConstant(Constant node) => visitPrimitive(node);
417 T visitThis(This node) => visitPrimitive(node); 425 T visitThis(This node) => visitPrimitive(node);
426 T visitSuper(Super node) => visitPrimitive(node);
418 T visitInvokeConstConstructor(InvokeConstConstructor node) => visitPrimitive(n ode); 427 T visitInvokeConstConstructor(InvokeConstConstructor node) => visitPrimitive(n ode);
419 T visitParameter(Parameter node) => visitPrimitive(node); 428 T visitParameter(Parameter node) => visitPrimitive(node);
420 T visitContinuation(Continuation node) => visitDefinition(node); 429 T visitContinuation(Continuation node) => visitDefinition(node);
421 430
422 // Conditions. 431 // Conditions.
423 T visitIsTrue(IsTrue node) => visitCondition(node); 432 T visitIsTrue(IsTrue node) => visitCondition(node);
424 } 433 }
425 434
426 /// Generate a Lisp-like S-expression representation of an IR node as a string. 435 /// Generate a Lisp-like S-expression representation of an IR node as a string.
427 /// The representation is not pretty-printed, but it can easily be quoted and 436 /// The representation is not pretty-printed, but it can easily be quoted and
(...skipping 255 matching lines...) Expand 10 before | Expand all | Expand 10 after
683 for (int i = node.parameters.length - 1; i >= 0; --i) { 692 for (int i = node.parameters.length - 1; i >= 0; --i) {
684 release(node.parameters[i]); 693 release(node.parameters[i]);
685 } 694 }
686 } 695 }
687 696
688 void visitIsTrue(IsTrue node) { 697 void visitIsTrue(IsTrue node) {
689 visitReference(node.value); 698 visitReference(node.value);
690 } 699 }
691 700
692 } 701 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698