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

Unified Diff: tests/language/first_class_types_literals_test.dart

Issue 214373002: Correctly recognize type literals in literal lists and maps in an invocation context. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 years, 9 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/resolution/members.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/language/first_class_types_literals_test.dart
diff --git a/tests/language/first_class_types_literals_test.dart b/tests/language/first_class_types_literals_test.dart
index 8ba570a6baac87597a6ca6e526606756a679c734..422628a42475594e44d2a03c5b85738f933d343b 100644
--- a/tests/language/first_class_types_literals_test.dart
+++ b/tests/language/first_class_types_literals_test.dart
@@ -15,6 +15,17 @@ sameType(a, b) {
}
main() {
+ void foo(a) {}
+
+ // Test that literals can be used in different contexts.
+ [int];
+ ([int]);
+ foo([int]);
+ [int].length;
+ ({1: int});
+ foo({1: int});
+ ({1: int}).keys;
+
// Test type literals.
Expect.equals(int, int);
Expect.notEquals(int, num);
« no previous file with comments | « sdk/lib/_internal/compiler/implementation/resolution/members.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698