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

Side by Side Diff: tests/language/type_propagation3_test.dart

Issue 2771453003: Format all tests. (Closed)
Patch Set: Format files Created 3 years, 8 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
OLDNEW
1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, 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 // Regression test for dart2js that used to generate wrong code for 5 // Regression test for dart2js that used to generate wrong code for
6 // it. The bug happened in the SSA type propagation. 6 // it. The bug happened in the SSA type propagation.
7 7
8 class A { 8 class A {
9 next() => new B(); 9 next() => new B();
10 doIt() => null; 10 doIt() => null;
(...skipping 28 matching lines...) Expand all
39 39
40 main() { 40 main() {
41 var a = new A(); 41 var a = new A();
42 for (var i in [42]) { 42 for (var i in [42]) {
43 a = a.next(); 43 a = a.next();
44 } 44 }
45 45
46 // (1, 5) 46 // (1, 5)
47 47
48 var b = a; 48 var b = a;
49 while (b.isEmpty) { // (4, 6) 49 while (b.isEmpty) {
50 // (4, 6)
50 b.foo(); // (3, 7) 51 b.foo(); // (3, 7)
51 b.bar(); // (8) 52 b.bar(); // (8)
52 b = b.doIt(); // (2) 53 b = b.doIt(); // (2)
53 } 54 }
54 55
55 if (!entered) throw 'Test failed'; 56 if (!entered) throw 'Test failed';
56 } 57 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698