Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(6)

Side by Side Diff: tests/compiler/dart2js/js_backend_cps_ir_operators.dart

Issue 800433003: First version of typr propagation in the new IR. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Add type arguments, fix join and tests. Created 6 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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 operators. 5 // Tests of operators.
6 6
7 library operators_tests; 7 library operators_tests;
8 8
9 import 'js_backend_cps_ir_test.dart'; 9 import 'js_backend_cps_ir_test.dart';
10 10
11 const List<TestEntry> tests = const [ 11 const List<TestEntry> tests = const [
12 const TestEntry("main() { return true ? 42 : 'foo'; }"), 12 const TestEntry("main() { return true ? 42 : 'foo'; }"),
13 const TestEntry(""" 13 const TestEntry("""
14 foo() => foo; 14 foo() => foo();
15 main() { 15 main() {
16 print(foo() ? "hello world" : "bad bad"); 16 print(foo() ? "hello world" : "bad bad");
17 }""", 17 }""",
18 """function() { 18 """function() {
19 P.print(P.identical(V.foo(), true) ? "hello world" : "bad bad"); 19 P.print(P.identical(V.foo(), true) ? "hello world" : "bad bad");
20 return null; 20 return null;
21 }"""), 21 }"""),
22 const TestEntry(""" 22 const TestEntry("""
23 get foo => foo; 23 get foo => foo;
24 main() { 24 main() {
(...skipping 11 matching lines...) Expand all
36 return null; 36 return null;
37 }"""), 37 }"""),
38 const TestEntry(""" 38 const TestEntry("""
39 get foo => foo; 39 get foo => foo;
40 main() { print(foo || foo); }""", 40 main() { print(foo || foo); }""",
41 """function() { 41 """function() {
42 P.print(P.identical(V.foo(), true) || P.identical(V.foo(), true)); 42 P.print(P.identical(V.foo(), true) || P.identical(V.foo(), true));
43 return null; 43 return null;
44 }"""), 44 }"""),
45 ]; 45 ];
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698