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

Unified Diff: tests/compiler/dart2js/mock_libraries.dart

Issue 1320503003: dart2js: add initial support for lookup-maps (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 5 years, 3 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
Index: tests/compiler/dart2js/mock_libraries.dart
diff --git a/tests/compiler/dart2js/mock_libraries.dart b/tests/compiler/dart2js/mock_libraries.dart
index d70afdb1fb57d9847104d7d957c88952b09262c0..2031cf035b410271e46b90e64ab8ae2ec2fce8cb 100644
--- a/tests/compiler/dart2js/mock_libraries.dart
+++ b/tests/compiler/dart2js/mock_libraries.dart
@@ -398,3 +398,19 @@ const Map<String, String> DEFAULT_MIRRORS_LIBRARY = const <String, String>{
'MirrorSystem': 'class MirrorSystem {}',
'MirrorsUsed': 'class MirrorsUsed {}',
};
+
+const Map<String, String> DEFAULT_LOOKUP_MAP_LIBRARY = const <String, String>{
+ 'LookupMap': r'''
+ class LookupMap<T> {
+ final _key;
+ final _value;
+ final _entries;
+ final _nestedMaps;
+
+ const LookupMap(this._entries, [this._nestedMaps = const []])
+ : _key = null, _value = null;
+
+ const LookupMap.pair(this._key, this._value)
+ : _entries = const [], _nestedMaps = const [];
+ }''',
+};

Powered by Google App Engine
This is Rietveld 408576698