| OLD | NEW |
| 1 // Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2016, 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.md file. | 3 // BSD-style license that can be found in the LICENSE.md file. |
| 4 | 4 |
| 5 import 'package:kernel/ast.dart' as ir; | 5 import 'package:kernel/ast.dart' as ir; |
| 6 import 'package:kernel/frontend/accessors.dart' | 6 import 'package:kernel/frontend/accessors.dart' |
| 7 show | 7 show |
| 8 Accessor, | 8 Accessor, |
| 9 IndexAccessor, | 9 IndexAccessor, |
| 10 NullAwarePropertyAccessor, | 10 NullAwarePropertyAccessor, |
| (...skipping 1515 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1526 Send node, Node receiverNode, NodeList arguments, Selector selector, _) { | 1526 Send node, Node receiverNode, NodeList arguments, Selector selector, _) { |
| 1527 ir.VariableDeclaration receiver = | 1527 ir.VariableDeclaration receiver = |
| 1528 makeOrReuseVariable(visitForValue(receiverNode)); | 1528 makeOrReuseVariable(visitForValue(receiverNode)); |
| 1529 return makeLet( | 1529 return makeLet( |
| 1530 receiver, | 1530 receiver, |
| 1531 new ir.ConditionalExpression( | 1531 new ir.ConditionalExpression( |
| 1532 buildIsNull(new ir.VariableGet(receiver)), | 1532 buildIsNull(new ir.VariableGet(receiver)), |
| 1533 new ir.NullLiteral(), | 1533 new ir.NullLiteral(), |
| 1534 associateNode( | 1534 associateNode( |
| 1535 buildInvokeSelector(new ir.VariableGet(receiver), selector, | 1535 buildInvokeSelector(new ir.VariableGet(receiver), selector, |
| 1536 buildArguments(arguments)), | 1536 buildArguments(arguments)), |
| 1537 receiverNode), | 1537 receiverNode), |
| 1538 null)); | 1538 null)); |
| 1539 } | 1539 } |
| 1540 | 1540 |
| 1541 @override | 1541 @override |
| 1542 ir.Expression visitIfNotNullDynamicPropertySet( | 1542 ir.Expression visitIfNotNullDynamicPropertySet( |
| 1543 SendSet node, Node receiver, Name name, Node rhs, _) { | 1543 SendSet node, Node receiver, Name name, Node rhs, _) { |
| 1544 return buildNullAwarePropertyAccessor(receiver, name) | 1544 return buildNullAwarePropertyAccessor(receiver, name) |
| 1545 .buildAssignment(visitForValue(rhs), voidContext: isVoidContext); | 1545 .buildAssignment(visitForValue(rhs), voidContext: isVoidContext); |
| 1546 } | 1546 } |
| (...skipping 1300 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2847 : this(null, true, node, initializers); | 2847 : this(null, true, node, initializers); |
| 2848 | 2848 |
| 2849 accept(ir.Visitor v) => throw "unsupported"; | 2849 accept(ir.Visitor v) => throw "unsupported"; |
| 2850 | 2850 |
| 2851 visitChildren(ir.Visitor v) => throw "unsupported"; | 2851 visitChildren(ir.Visitor v) => throw "unsupported"; |
| 2852 | 2852 |
| 2853 String toString() { | 2853 String toString() { |
| 2854 return "IrFunction($kind, $isConstructor, $node, $initializers)"; | 2854 return "IrFunction($kind, $isConstructor, $node, $initializers)"; |
| 2855 } | 2855 } |
| 2856 } | 2856 } |
| OLD | NEW |