| OLD | NEW |
| 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, 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 ssa; | 5 part of ssa; |
| 6 | 6 |
| 7 abstract class HVisitor<R> { | 7 abstract class HVisitor<R> { |
| 8 R visitAdd(HAdd node); | 8 R visitAdd(HAdd node); |
| 9 R visitAwait(HAwait node); | 9 R visitAwait(HAwait node); |
| 10 R visitBitAnd(HBitAnd node); | 10 R visitBitAnd(HBitAnd node); |
| (...skipping 2896 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2907 bool accept(HStatementInformationVisitor visitor) => | 2907 bool accept(HStatementInformationVisitor visitor) => |
| 2908 visitor.visitLabeledBlockInfo(this); | 2908 visitor.visitLabeledBlockInfo(this); |
| 2909 } | 2909 } |
| 2910 | 2910 |
| 2911 class LoopTypeVisitor extends ast.Visitor { | 2911 class LoopTypeVisitor extends ast.Visitor { |
| 2912 const LoopTypeVisitor(); | 2912 const LoopTypeVisitor(); |
| 2913 int visitNode(ast.Node node) => HLoopBlockInformation.NOT_A_LOOP; | 2913 int visitNode(ast.Node node) => HLoopBlockInformation.NOT_A_LOOP; |
| 2914 int visitWhile(ast.While node) => HLoopBlockInformation.WHILE_LOOP; | 2914 int visitWhile(ast.While node) => HLoopBlockInformation.WHILE_LOOP; |
| 2915 int visitFor(ast.For node) => HLoopBlockInformation.FOR_LOOP; | 2915 int visitFor(ast.For node) => HLoopBlockInformation.FOR_LOOP; |
| 2916 int visitDoWhile(ast.DoWhile node) => HLoopBlockInformation.DO_WHILE_LOOP; | 2916 int visitDoWhile(ast.DoWhile node) => HLoopBlockInformation.DO_WHILE_LOOP; |
| 2917 int visitForIn(ast.ForIn node) => HLoopBlockInformation.FOR_IN_LOOP; | 2917 int visitAsyncForIn(ast.AsyncForIn node) => HLoopBlockInformation.FOR_IN_LOOP; |
| 2918 int visitSyncForIn(ast.SyncForIn node) => HLoopBlockInformation.FOR_IN_LOOP; |
| 2918 int visitSwitchStatement(ast.SwitchStatement node) => | 2919 int visitSwitchStatement(ast.SwitchStatement node) => |
| 2919 HLoopBlockInformation.SWITCH_CONTINUE_LOOP; | 2920 HLoopBlockInformation.SWITCH_CONTINUE_LOOP; |
| 2920 } | 2921 } |
| 2921 | 2922 |
| 2922 class HLoopBlockInformation implements HStatementInformation { | 2923 class HLoopBlockInformation implements HStatementInformation { |
| 2923 static const int WHILE_LOOP = 0; | 2924 static const int WHILE_LOOP = 0; |
| 2924 static const int FOR_LOOP = 1; | 2925 static const int FOR_LOOP = 1; |
| 2925 static const int DO_WHILE_LOOP = 2; | 2926 static const int DO_WHILE_LOOP = 2; |
| 2926 static const int FOR_IN_LOOP = 3; | 2927 static const int FOR_IN_LOOP = 3; |
| 2927 static const int SWITCH_CONTINUE_LOOP = 4; | 2928 static const int SWITCH_CONTINUE_LOOP = 4; |
| (...skipping 222 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3150 class HDynamicType extends HRuntimeType { | 3151 class HDynamicType extends HRuntimeType { |
| 3151 HDynamicType(DynamicType dartType, TypeMask instructionType) | 3152 HDynamicType(DynamicType dartType, TypeMask instructionType) |
| 3152 : super(const <HInstruction>[], dartType, instructionType); | 3153 : super(const <HInstruction>[], dartType, instructionType); |
| 3153 | 3154 |
| 3154 accept(HVisitor visitor) => visitor.visitDynamicType(this); | 3155 accept(HVisitor visitor) => visitor.visitDynamicType(this); |
| 3155 | 3156 |
| 3156 int typeCode() => HInstruction.DYNAMIC_TYPE_TYPECODE; | 3157 int typeCode() => HInstruction.DYNAMIC_TYPE_TYPECODE; |
| 3157 | 3158 |
| 3158 bool typeEquals(HInstruction other) => other is HDynamicType; | 3159 bool typeEquals(HInstruction other) => other is HDynamicType; |
| 3159 } | 3160 } |
| OLD | NEW |