OLD | NEW |
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2014, 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.cps_ir.optimizers; | 5 part of dart2js.cps_ir.optimizers; |
6 | 6 |
7 /** | 7 /** |
8 * [ShrinkingReducer] applies shrinking reductions to CPS terms as described | 8 * [ShrinkingReducer] applies shrinking reductions to CPS terms as described |
9 * in 'Compiling with Continuations, Continued' by Andrew Kennedy. | 9 * in 'Compiling with Continuations, Continued' by Andrew Kennedy. |
10 */ | 10 */ |
(...skipping 640 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
651 processSetField(SetField node) { | 651 processSetField(SetField node) { |
652 node.object.parent = node; | 652 node.object.parent = node; |
653 node.value.parent = node; | 653 node.value.parent = node; |
654 node.body.parent = node; | 654 node.body.parent = node; |
655 } | 655 } |
656 | 656 |
657 processGetField(GetField node) { | 657 processGetField(GetField node) { |
658 node.object.parent = node; | 658 node.object.parent = node; |
659 } | 659 } |
660 | 660 |
| 661 processGetStatic(GetStatic node) { |
| 662 } |
| 663 |
| 664 processSetStatic(SetStatic node) { |
| 665 node.value.parent = node; |
| 666 node.body.parent = node; |
| 667 } |
| 668 |
661 processGetMutableVariable(GetMutableVariable node) { | 669 processGetMutableVariable(GetMutableVariable node) { |
662 node.variable.parent = node; | 670 node.variable.parent = node; |
663 } | 671 } |
664 | 672 |
665 processCreateInstance(CreateInstance node) { | 673 processCreateInstance(CreateInstance node) { |
666 node.arguments.forEach((Reference ref) => ref.parent = node); | 674 node.arguments.forEach((Reference ref) => ref.parent = node); |
667 node.typeInformation.forEach((Reference ref) => ref.parent = node); | 675 node.typeInformation.forEach((Reference ref) => ref.parent = node); |
668 } | 676 } |
669 | 677 |
670 processCreateBox(CreateBox node) { | 678 processCreateBox(CreateBox node) { |
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
724 } | 732 } |
725 | 733 |
726 String toString() => "$kind: $node"; | 734 String toString() => "$kind: $node"; |
727 } | 735 } |
728 | 736 |
729 /// A dummy class used solely to mark nodes as deleted once they are removed | 737 /// A dummy class used solely to mark nodes as deleted once they are removed |
730 /// from a term. | 738 /// from a term. |
731 class _DeletedNode extends Node { | 739 class _DeletedNode extends Node { |
732 accept(_) => null; | 740 accept(_) => null; |
733 } | 741 } |
OLD | NEW |