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

Unified Diff: tests/compiler/dart2js/backend_dart/sexpr_unstringifier.dart

Issue 658103003: Support map and list literals in analyzer2dart. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Use LiteralMapEntry to ensure build order Created 6 years, 2 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « sdk/lib/_internal/compiler/implementation/elements/modelx.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/compiler/dart2js/backend_dart/sexpr_unstringifier.dart
diff --git a/tests/compiler/dart2js/backend_dart/sexpr_unstringifier.dart b/tests/compiler/dart2js/backend_dart/sexpr_unstringifier.dart
index f0954c654f8a8e8cb6bc76cd3576d9b125aa8dd0..61c846711ac88f2e3456020137ff2f08199b43a5 100644
--- a/tests/compiler/dart2js/backend_dart/sexpr_unstringifier.dart
+++ b/tests/compiler/dart2js/backend_dart/sexpr_unstringifier.dart
@@ -659,8 +659,13 @@ class SExpressionUnstringifier {
List<Primitive> keys = parsePrimitiveList();
List<Primitive> values = parsePrimitiveList();
+ List<LiteralMapEntry> entries = <LiteralMapEntry>[];
+ for (int i = 0; i < keys.length; i++) {
+ entries.add(new LiteralMapEntry(keys[i], values[i]));
+ }
+
tokens.consumeEnd();
- return new LiteralMap(null, keys, values);
+ return new LiteralMap(null, entries);
}
/// (ReifyTypeVar type)
« no previous file with comments | « sdk/lib/_internal/compiler/implementation/elements/modelx.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698