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

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

Issue 761983002: Support for map literals in cps js emitter (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Address comments Created 6 years 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 | « pkg/compiler/lib/src/universe/universe.dart ('k') | no next file » | 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) 2014, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2014, 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 of literals. 5 // Tests of literals.
6 6
7 library literals_tests; 7 library literals_tests;
8 8
9 import 'js_backend_cps_ir_test.dart'; 9 import 'js_backend_cps_ir_test.dart';
10 10
11 const List<TestEntry> tests = const [ 11 const List<TestEntry> tests = const [
12 const TestEntry(""" 12 const TestEntry("""
13 main() { 13 main() {
14 print([]); 14 print([]);
15 print([1]); 15 print([1]);
16 print([1, 2]); 16 print([1, 2]);
17 print([1, [1, 2]]); 17 print([1, [1, 2]]);
18 print({});
19 print({1: 2});
20 print({[1, 2]: [3, 4]});
18 } 21 }
19 """, 22 """,
20 """ 23 r"""
21 function() { 24 function() {
22 P.print([]); 25 P.print([]);
23 P.print([1]); 26 P.print([1]);
24 P.print([1, 2]); 27 P.print([1, 2]);
25 P.print([1, [1, 2]]); 28 P.print([1, [1, 2]]);
29 P.print(P.LinkedHashMap_LinkedHashMap$_empty());
30 P.print(P.LinkedHashMap_LinkedHashMap$_literal([1, 2]));
31 P.print(P.LinkedHashMap_LinkedHashMap$_literal([[1, 2], [3, 4]]));
26 return null; 32 return null;
27 }"""), 33 }"""),
28 ]; 34 ];
OLDNEW
« no previous file with comments | « pkg/compiler/lib/src/universe/universe.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698