Index: lib/compiler/implementation/ssa/codegen.dart |
diff --git a/lib/compiler/implementation/ssa/codegen.dart b/lib/compiler/implementation/ssa/codegen.dart |
index 91f179dc4a9da9b9577922cbbe83d70de4e0b08f..90f33480dd0a8e97746adad9cb9677e351f97d6e 100644 |
--- a/lib/compiler/implementation/ssa/codegen.dart |
+++ b/lib/compiler/implementation/ssa/codegen.dart |
@@ -1446,13 +1446,16 @@ class SsaCodeGenerator implements HVisitor { |
} |
void visitIs(HIs node) { |
- Element element = node.typeExpression; |
+ Type type = node.typeName; |
ahe
2012/04/12 15:05:23
I don't see how typeName is an improvement over ty
|
+ Element element = type.element; |
if (element.kind === ElementKind.TYPE_VARIABLE) { |
compiler.unimplemented("visitIs for type variables"); |
ahe
2012/04/12 15:05:23
Please add this argument: "instruction: node"
|
+ } else if (element.kind === ElementKind.TYPEDEF) { |
+ compiler.unimplemented("visitIs for typedefs"); |
ahe
2012/04/12 15:05:23
Ditto.
|
} |
compiler.registerIsCheck(element); |
LibraryElement coreLibrary = compiler.coreLibrary; |
- ClassElement objectClass = coreLibrary.find(const SourceString('Object')); |
+ ClassElement objectClass = compiler.objectClass; |
HInstruction input = node.expression; |
if (node.nullOk) { |
beginExpression(JSPrecedence.LOGICAL_OR_PRECEDENCE); |