OLD | NEW |
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2014, 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 // Tests of control flow statements. | 5 // Tests of control flow statements. |
6 | 6 |
7 library control_flow_tests; | 7 library control_flow_tests; |
8 | 8 |
9 import 'js_backend_cps_ir.dart'; | 9 import 'js_backend_cps_ir.dart'; |
10 | 10 |
(...skipping 112 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
123 const TestEntry(""" | 123 const TestEntry(""" |
124 foo() => 2; | 124 foo() => 2; |
125 main() { | 125 main() { |
126 if (foo()) { | 126 if (foo()) { |
127 print('bad'); | 127 print('bad'); |
128 } else { | 128 } else { |
129 print('good'); | 129 print('good'); |
130 } | 130 } |
131 }""",""" | 131 }""",""" |
132 function() { | 132 function() { |
133 P.identical(V.foo(), true) ? P.print("bad") : P.print("good"); | 133 V.foo(); |
| 134 P.print("good"); |
134 return null; | 135 return null; |
135 }"""), | 136 }"""), |
136 ]; | 137 ]; |
137 | 138 |
138 void main() { | 139 void main() { |
139 runTests(tests); | 140 runTests(tests); |
140 } | 141 } |
OLD | NEW |