| Index: lib/compiler/implementation/ssa/codegen.dart
|
| diff --git a/lib/compiler/implementation/ssa/codegen.dart b/lib/compiler/implementation/ssa/codegen.dart
|
| index 4c76a2cf502db68b3bd021ea2f6fcd6bf339db65..9e68b48bc386adab62815142440415b3909bc2e8 100644
|
| --- a/lib/compiler/implementation/ssa/codegen.dart
|
| +++ b/lib/compiler/implementation/ssa/codegen.dart
|
| @@ -1488,6 +1488,10 @@ class SsaCodeGenerator implements HVisitor, HBlockInformationVisitor {
|
| endExpression(JSPrecedence.PREFIX_PRECEDENCE);
|
| }
|
|
|
| + void checkExtendableArray(HInstruction input) {
|
| + compiler.unimplemented("check extendable array");
|
| + }
|
| +
|
| void checkNull(HInstruction input) {
|
| beginExpression(JSPrecedence.EQUALITY_PRECEDENCE);
|
| use(input, JSPrecedence.EQUALITY_PRECEDENCE);
|
| @@ -1676,6 +1680,15 @@ class SsaOptimizedCodeGenerator extends SsaCodeGenerator {
|
| checkString(input, '!==');
|
| buffer.add(') ');
|
| bailout(node, 'Not a string');
|
| + } else if (node.isExtendableArray()) {
|
| + buffer.add('if (');
|
| + checkObject(input, '!==');
|
| + buffer.add('||');
|
| + checkArray(input, '!==');
|
| + buffer.add('||');
|
| + checkExtendableArray(input);
|
| + buffer.add(') ');
|
| + bailout(node, 'Not an extendable array');
|
| } else if (node.isMutableArray()) {
|
| buffer.add('if (');
|
| checkObject(input, '!==');
|
| @@ -1685,14 +1698,14 @@ class SsaOptimizedCodeGenerator extends SsaCodeGenerator {
|
| checkImmutableArray(input);
|
| buffer.add(') ');
|
| bailout(node, 'Not a mutable array');
|
| - } else if (node.isArray()) {
|
| + } else if (node.isReadableArray()) {
|
| buffer.add('if (');
|
| checkObject(input, '!==');
|
| buffer.add('||');
|
| checkArray(input, '!==');
|
| buffer.add(') ');
|
| bailout(node, 'Not an array');
|
| - } else if (node.isStringOrArray()) {
|
| + } else if (node.isIndexablePrimitive()) {
|
| buffer.add('if (');
|
| checkString(input, '!==');
|
| buffer.add(' && (');
|
|
|