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

Side by Side Diff: tests/compiler/dart2js/ssa_phi_codegen_test.dart

Issue 11368150: Updated tests/compiler/* to use new library syntax. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 8 years, 1 month 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
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 // Test that parameters keep their names in the output. 4 // Test that parameters keep their names in the output.
5 5
6 #import("compiler_helper.dart"); 6 import 'compiler_helper.dart';
7 7
8 const String TEST_ONE = r""" 8 const String TEST_ONE = r"""
9 void foo(bar) { 9 void foo(bar) {
10 var a = 1; 10 var a = 1;
11 if (bar) { 11 if (bar) {
12 a = 2; 12 a = 2;
13 } else { 13 } else {
14 a = 3; 14 a = 3;
15 } 15 }
16 print(a); 16 print(a);
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
65 // Check that we don't have 'd = d' (using regexp back references). 65 // Check that we don't have 'd = d' (using regexp back references).
66 compileAndDoNotMatchFuzzy(TEST_THREE, 'foo', '(x) = \1'); 66 compileAndDoNotMatchFuzzy(TEST_THREE, 'foo', '(x) = \1');
67 compileAndMatchFuzzy(TEST_THREE, 'foo', 'return x'); 67 compileAndMatchFuzzy(TEST_THREE, 'foo', 'return x');
68 // Check that a store just after the declaration of the local 68 // Check that a store just after the declaration of the local
69 // only generates one instruction. 69 // only generates one instruction.
70 compileAndMatchFuzzy(TEST_THREE, 'foo', 'x = 42'); 70 compileAndMatchFuzzy(TEST_THREE, 'foo', 'x = 42');
71 71
72 var generated = compile(TEST_FOUR, entry: 'foo'); 72 var generated = compile(TEST_FOUR, entry: 'foo');
73 compileAndDoNotMatchFuzzy(TEST_FOUR, 'foo', '(x) = \1;'); 73 compileAndDoNotMatchFuzzy(TEST_FOUR, 'foo', '(x) = \1;');
74 } 74 }
OLDNEW
« no previous file with comments | « tests/compiler/dart2js/rewrite_better_user_test.dart ('k') | tests/compiler/dart2js/static_closure_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698