OLD | NEW |
| (Empty) |
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 | |
3 // BSD-style license that can be found in the LICENSE file. | |
4 // Dart test program to test arithmetic operations. | |
5 // VMOptions=--optimization-counter-threshold=10 --checked --no-background-compi
lation | |
6 | |
7 // This test crashes if we recompute type of AssertAssignableInstr based on its | |
8 // output types. By doing that we would eliminate not only the unnecessary | |
9 // AssertAssignableInstr but also the trailing class check. | |
10 | |
11 main() { | |
12 // Foul up IC data in integer's unary minus. | |
13 var y = -0x80000000; | |
14 testInt64List(); | |
15 } | |
16 | |
17 testInt64List() { | |
18 var array = new List(10); | |
19 testInt64ListImpl(array); | |
20 } | |
21 | |
22 testInt64ListImpl(array) { | |
23 for (int i = 0; i < 10; ++i) {} | |
24 int sum = 0; | |
25 for (int i = 0; i < 10; ++i) { | |
26 array[i] = -0x80000000000000 + i; | |
27 } | |
28 } | |
OLD | NEW |