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

Side by Side Diff: tests/standalone/left_shift_bit_and_op_test.dart

Issue 12212016: Remove Expect from core library. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Add deprecation comment for ExpectException and revert one test. Created 7 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 | Annotate | Revision Log
« no previous file with comments | « tests/standalone/io/zlib_test.dart ('k') | tests/standalone/medium_integer_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) 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 // Tests optimizing (a << b) & c if c is a Smi constant. 5 // Tests optimizing (a << b) & c if c is a Smi constant.
6 6
7 import "package:expect/expect.dart";
8
7 main() { 9 main() {
8 checkshiftAnd32(); 10 checkshiftAnd32();
9 checkShiftAnd64(); 11 checkShiftAnd64();
10 // Optimize shiftAnd32. 12 // Optimize shiftAnd32.
11 for (int i = 0; i < 10000; i++) { 13 for (int i = 0; i < 10000; i++) {
12 A.shiftAnd32(12, 17); 14 A.shiftAnd32(12, 17);
13 A.shiftAnd64(12, 17); 15 A.shiftAnd64(12, 17);
14 Expect.equals(72, A.multipleConstantUses(3, 4)); 16 Expect.equals(72, A.multipleConstantUses(3, 4));
15 Expect.equals(34493956096, A.multipleShiftUse(134742016, 8)); 17 Expect.equals(34493956096, A.multipleShiftUse(134742016, 8));
16 } 18 }
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after
66 } 68 }
67 69
68 foo(x) { return x & 0xf; } 70 foo(x) { return x & 0xf; }
69 } 71 }
70 72
71 class B { foo(x) { return x; } } 73 class B { foo(x) { return x; } }
72 74
73 bar (o) { 75 bar (o) {
74 return o.foo(1 << 32); 76 return o.foo(1 << 32);
75 } 77 }
OLDNEW
« no previous file with comments | « tests/standalone/io/zlib_test.dart ('k') | tests/standalone/medium_integer_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698