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

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

Issue 908863003: dart2js cps: Handle optional parameters in builder. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Fix static invoke Created 5 years, 10 months 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 // VMOptions=-DUSE_CPS_IR=true 4 // VMOptions=-DUSE_CPS_IR=true
5 5
6 // Tests for basic functionality. 6 // Tests for basic functionality.
7 7
8 library basic_tests; 8 library basic_tests;
9 9
10 import 'js_backend_cps_ir.dart'; 10 import 'js_backend_cps_ir.dart';
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
47 foo(0); 47 foo(0);
48 foo(1, 2); 48 foo(1, 2);
49 bar(3); 49 bar(3);
50 bar(4, b: 5); 50 bar(4, b: 5);
51 bar(6, c: 7); 51 bar(6, c: 7);
52 bar(8, b: 9, c: 10); 52 bar(8, b: 9, c: 10);
53 } 53 }
54 """, 54 """,
55 """ 55 """
56 function() { 56 function() {
57 var v0, v1;
57 V.foo(0, "b"); 58 V.foo(0, "b");
58 V.foo(1, 2); 59 V.foo(1, 2);
59 V.bar(3, "b", "c"); 60 V.bar(3, "b", "c");
60 V.bar(4, 5, "c"); 61 V.bar(4, 5, "c");
61 V.bar(6, "b", 7); 62 v0 = 6;
63 v1 = 7;
64 V.bar(v0, "b", v1);
62 V.bar(8, 9, 10); 65 V.bar(8, 9, 10);
63 return null; 66 return null;
64 }"""), 67 }"""),
65 const TestEntry( 68 const TestEntry(
66 """ 69 """
67 foo(a) { 70 foo(a) {
68 return a; 71 return a;
69 } 72 }
70 main() { 73 main() {
71 var a = 10; 74 var a = 10;
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after
130 function() { 133 function() {
131 P.print(P.DateTime$now().isBefore$1(P.DateTime$now())); 134 P.print(P.DateTime$now().isBefore$1(P.DateTime$now()));
132 return null; 135 return null;
133 }"""), 136 }"""),
134 ]; 137 ];
135 138
136 139
137 void main() { 140 void main() {
138 runTests(tests); 141 runTests(tests);
139 } 142 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698