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

Unified Diff: pkg/analyzer/test/src/task/strong/inferred_type_test.dart

Issue 2214123002: add a regression test for #26431, which is now fixed (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 4 years, 4 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/analyzer/test/src/task/strong/inferred_type_test.dart
diff --git a/pkg/analyzer/test/src/task/strong/inferred_type_test.dart b/pkg/analyzer/test/src/task/strong/inferred_type_test.dart
index 32000e99686c3ced31ac7b2e5660275db7477a37..fe2bdfb5b3bf259875a65f89eba2c612f3d953e7 100644
--- a/pkg/analyzer/test/src/task/strong/inferred_type_test.dart
+++ b/pkg/analyzer/test/src/task/strong/inferred_type_test.dart
@@ -588,6 +588,16 @@ class C2 implements A, B {
''');
}
+ void test_constructors_downwardsWithConstraint() {
+ // Regression test for https://github.com/dart-lang/sdk/issues/26431
+ checkFile(r'''
+class Foo<T extends Iterable> {}
+void main() {
+ Foo<List> foo = /*info:INFERRED_TYPE_ALLOCATION*/new Foo();
+}
+ ''');
+ }
+
void test_constructors_inferenceFBounded() {
// Regression for https://github.com/dart-lang/sdk/issues/26990
var unit = checkFile('''
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698