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

Side by Side Diff: frog/tests/leg_only/phi_elimination_test.dart

Issue 10536169: Move frog/tests/{leg,leg_only,frog_native} to tests/compiler/. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 8 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 | « frog/tests/leg_only/parameter_bailout_test.dart ('k') | frog/tests/leg_only/phi_gvn_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
(Empty)
1 // Copyright (c) 2011, 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
5 void bar() {
6 var a = 0;
7 var c = 0;
8
9 if (a == 0) c = a++;
10 else c = a--;
11
12 Expect.equals(1, a);
13 Expect.equals(0, c);
14
15 if (a == 0) c = a++;
16 else c = a--;
17
18 Expect.equals(0, a);
19 Expect.equals(1, c);
20 }
21
22 void foo() {
23 var a = 0;
24 var c = 0;
25
26 if (a == 0) {
27 c = a;
28 a = a + 1;
29 } else {
30 c = a;
31 a = a - 1;
32 }
33
34 Expect.equals(1, a);
35 Expect.equals(0, c);
36
37 if (a == 0) {
38 c = a;
39 a = a + 1;
40 } else {
41 c = a;
42 a = a - 1;
43 }
44
45 Expect.equals(0, a);
46 Expect.equals(1, c);
47 }
48
49 main() {
50 foo();
51 bar();
52 }
OLDNEW
« no previous file with comments | « frog/tests/leg_only/parameter_bailout_test.dart ('k') | frog/tests/leg_only/phi_gvn_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698