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 file. | 3 // BSD-style license that can be found in the LICENSE file. |
4 | 4 |
5 /// Functions for asserting equivalence across serialization. | 5 /// Functions for asserting equivalence across serialization. |
6 | 6 |
7 library dart2js.serialization.equivalence; | 7 library dart2js.serialization.equivalence; |
8 | 8 |
9 import '../common/resolution.dart'; | 9 import '../common/resolution.dart'; |
10 import '../constants/expressions.dart'; | 10 import '../constants/expressions.dart'; |
(...skipping 1205 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1216 testNodes(node1, node2, 'update', node1.update, node2.update) && | 1216 testNodes(node1, node2, 'update', node1.update, node2.update) && |
1217 testNodes(node1, node2, 'body', node1.body, node2.body); | 1217 testNodes(node1, node2, 'body', node1.body, node2.body); |
1218 } | 1218 } |
1219 | 1219 |
1220 @override | 1220 @override |
1221 bool visitForIn(ForIn node1, ForIn node2) { | 1221 bool visitForIn(ForIn node1, ForIn node2) { |
1222 return testNodes( | 1222 return testNodes( |
1223 node1, node2, 'condition', node1.condition, node2.condition) && | 1223 node1, node2, 'condition', node1.condition, node2.condition) && |
1224 testNodes( | 1224 testNodes( |
1225 node1, node2, 'expression', node1.expression, node2.expression) && | 1225 node1, node2, 'expression', node1.expression, node2.expression) && |
1226 testNodes(node1, node2, 'body', node1.expression, node2.body) && | 1226 testNodes(node1, node2, 'body', node1.body, node2.body) && |
1227 testNodes(node1, node2, 'declaredIdentifier', node1.declaredIdentifier, | 1227 testNodes(node1, node2, 'declaredIdentifier', node1.declaredIdentifier, |
1228 node2.declaredIdentifier); | 1228 node2.declaredIdentifier); |
1229 } | 1229 } |
1230 | 1230 |
1231 @override | 1231 @override |
1232 bool visitFunctionDeclaration( | 1232 bool visitFunctionDeclaration( |
1233 FunctionDeclaration node1, FunctionDeclaration node2) { | 1233 FunctionDeclaration node1, FunctionDeclaration node2) { |
1234 return testNodes(node1, node2, 'function', node1.function, node2.function); | 1234 return testNodes(node1, node2, 'function', node1.function, node2.function); |
1235 } | 1235 } |
1236 | 1236 |
(...skipping 450 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1687 @override | 1687 @override |
1688 bool visitStatement(Statement node1, Statement node2) { | 1688 bool visitStatement(Statement node1, Statement node2) { |
1689 throw new UnsupportedError('Unexpected nodes: $node1 <> $node2'); | 1689 throw new UnsupportedError('Unexpected nodes: $node1 <> $node2'); |
1690 } | 1690 } |
1691 | 1691 |
1692 @override | 1692 @override |
1693 bool visitStringNode(StringNode node1, StringNode node2) { | 1693 bool visitStringNode(StringNode node1, StringNode node2) { |
1694 throw new UnsupportedError('Unexpected nodes: $node1 <> $node2'); | 1694 throw new UnsupportedError('Unexpected nodes: $node1 <> $node2'); |
1695 } | 1695 } |
1696 } | 1696 } |
OLD | NEW |