Chromium Code Reviews| Index: dart/sdk/lib/_internal/compiler/implementation/ssa/nodes.dart |
| diff --git a/dart/sdk/lib/_internal/compiler/implementation/ssa/nodes.dart b/dart/sdk/lib/_internal/compiler/implementation/ssa/nodes.dart |
| index c72124e7fe92f54b838695329bb3fc37f6b2b1ff..8447cb87ef86b7e8c715d5665386ec3c81d08098 100644 |
| --- a/dart/sdk/lib/_internal/compiler/implementation/ssa/nodes.dart |
| +++ b/dart/sdk/lib/_internal/compiler/implementation/ssa/nodes.dart |
| @@ -67,6 +67,8 @@ abstract class HVisitor<R> { |
| R visitTry(HTry node); |
| R visitTypeConversion(HTypeConversion node); |
| R visitTypeKnown(HTypeKnown node); |
| + R visitFunctionType(HFunctionType node); |
| + R visitReadTypeVariable(HReadTypeVariable node); |
| } |
| abstract class HGraphVisitor { |
| @@ -346,6 +348,8 @@ class HBaseVisitor extends HGraphVisitor implements HVisitor { |
| visitIs(HIs node) => visitInstruction(node); |
| visitTypeConversion(HTypeConversion node) => visitCheck(node); |
| visitTypeKnown(HTypeKnown node) => visitCheck(node); |
| + visitFunctionType(HFunctionType node) => visitInstruction(node); |
| + visitReadTypeVariable(HReadTypeVariable node) => visitInstruction(node); |
| } |
| class SubGraph { |
| @@ -2717,8 +2721,6 @@ class HTryBlockInformation implements HStatementInformation { |
| visitor.visitTryInfo(this); |
| } |
| - |
| - |
| class HSwitchBlockInformation implements HStatementInformation { |
| final HExpressionInformation expression; |
| final List<List<Constant>> matchExpressions; |
| @@ -2742,3 +2744,32 @@ class HSwitchBlockInformation implements HStatementInformation { |
| bool accept(HStatementInformationVisitor visitor) => |
| visitor.visitSwitchInfo(this); |
| } |
| + |
| +class HReadTypeVariable extends HInstruction { |
| + /// The type variable being read. |
| + final TypeVariableType dartType; |
| + |
| + final bool hasReceiver; |
| + |
| + HReadTypeVariable(this.dartType, HInstruction receiver) |
| + : hasReceiver = true, |
| + super(<HInstruction>[receiver]); |
| + |
| + HReadTypeVariable.noReceiver(this.dartType, HInstruction typeArguments) |
| + : hasReceiver = false, |
| + super(<HInstruction>[typeArguments]); |
| + |
| + accept(HVisitor visitor) => visitor.visitReadTypeVariable(this); |
| +} |
| + |
| +class HFunctionType extends HInstruction { |
|
ngeoffray
2013/11/01 13:54:02
Could you remind me why can't you just do a new li
ahe
2013/11/04 17:23:45
I'm not sure how this interacts with GVN. Also, I'
|
| + final FunctionType dartType; |
| + |
| + HFunctionType(List<HInstruction> typeVariables, this.dartType) |
| + : super(typeVariables) { |
| + /* Element */ sourceElement = null; |
| + /* SourceFileLocation */ sourcePosition = null; |
| + } |
| + |
| + accept(HVisitor visitor) => visitor.visitFunctionType(this); |
| +} |