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

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

Issue 16398006: BREAKING CHANGE: Remove === and !== in the VM compiler (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 7 years, 6 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
« no previous file with comments | « tests/language/compile_time_constant_d_test.dart ('k') | tests/language/licm_test.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, 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 import "package:expect/expect.dart"; 5 import "package:expect/expect.dart";
6 6
7 class A { 7 class A {
8 final x; 8 final x;
9 final y; 9 final y;
10 final z; 10 final z;
(...skipping 20 matching lines...) Expand all
31 const a8 = const A.named2(); 31 const a8 = const A.named2();
32 const a9 = const A.named2(x: 4, y: 3, z: 2, t: 1); 32 const a9 = const A.named2(x: 4, y: 3, z: 2, t: 1);
33 const a10 = const A.named2(x: 1, y: 2, z: 3, t: 4); 33 const a10 = const A.named2(x: 1, y: 2, z: 3, t: 4);
34 34
35 main() { 35 main() {
36 Expect.equals(3, a1.x); 36 Expect.equals(3, a1.x);
37 Expect.equals(499, a1.y); 37 Expect.equals(499, a1.y);
38 Expect.equals(99, a1.z); 38 Expect.equals(99, a1.z);
39 Expect.equals(100, a1.t); 39 Expect.equals(100, a1.t);
40 Expect.equals("A 3 499 99 100", a1.toString()); 40 Expect.equals("A 3 499 99 100", a1.toString());
41 Expect.isTrue(a1 === a2); 41 Expect.isTrue(identical(a1, a2));
42 Expect.isTrue(a1 === a4); 42 Expect.isTrue(identical(a1, a4));
43 Expect.isTrue(a1 === a5); 43 Expect.isTrue(identical(a1, a5));
44 44
45 Expect.equals(1, a3.x); 45 Expect.equals(1, a3.x);
46 Expect.equals(2, a3.y); 46 Expect.equals(2, a3.y);
47 Expect.equals(3, a3.z); 47 Expect.equals(3, a3.z);
48 Expect.equals(4, a3.t); 48 Expect.equals(4, a3.t);
49 Expect.equals("A 1 2 3 4", a3.toString()); 49 Expect.equals("A 1 2 3 4", a3.toString());
50 50
51 Expect.equals(3, a6.x); 51 Expect.equals(3, a6.x);
52 Expect.equals(499, a6.y); 52 Expect.equals(499, a6.y);
53 Expect.equals(1, a6.z); 53 Expect.equals(1, a6.z);
54 Expect.equals(2, a6.t); 54 Expect.equals(2, a6.t);
55 Expect.equals("A 3 499 1 2", a6.toString()); 55 Expect.equals("A 3 499 1 2", a6.toString());
56 56
57 Expect.equals(3, a7.x); 57 Expect.equals(3, a7.x);
58 Expect.equals(407, a7.y); 58 Expect.equals(407, a7.y);
59 Expect.equals(7, a7.z); 59 Expect.equals(7, a7.z);
60 Expect.equals(null, a7.t); 60 Expect.equals(null, a7.t);
61 Expect.equals("A 3 407 7 null", a7.toString()); 61 Expect.equals("A 3 407 7 null", a7.toString());
62 62
63 Expect.equals(null, a8.x); 63 Expect.equals(null, a8.x);
64 Expect.equals(null, a8.y); 64 Expect.equals(null, a8.y);
65 Expect.equals(null, a8.y); 65 Expect.equals(null, a8.y);
66 Expect.equals(null, a8.t); 66 Expect.equals(null, a8.t);
67 Expect.equals("A null null null null", a8.toString()); 67 Expect.equals("A null null null null", a8.toString());
68 68
69 Expect.isTrue(a3 === a9); 69 Expect.isTrue(identical(a3, a9));
70 70
71 Expect.equals(4, a10.x); 71 Expect.equals(4, a10.x);
72 Expect.equals(3, a10.y); 72 Expect.equals(3, a10.y);
73 Expect.equals(2, a10.z); 73 Expect.equals(2, a10.z);
74 Expect.equals(1, a10.t); 74 Expect.equals(1, a10.t);
75 Expect.equals("A 4 3 2 1", a10.toString()); 75 Expect.equals("A 4 3 2 1", a10.toString());
76 } 76 }
OLDNEW
« no previous file with comments | « tests/language/compile_time_constant_d_test.dart ('k') | tests/language/licm_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698