blob: 78ee25b65c6943888e3cc1246959c18a7831df67 [file] [log] [blame]
library /*isNonNullableByDefault*/;
//
// Problems in library:
//
// pkg/front_end/testcases/nnbd/list_constructor.dart:9:7: Error: Can't use the default List constructor.
// Try using List.filled instead.
// new List<T>(42);
// ^
//
// pkg/front_end/testcases/nnbd/list_constructor.dart:10:7: Error: Can't use the default List constructor.
// Try using List.filled instead.
// new List<int?>(42);
// ^
//
// pkg/front_end/testcases/nnbd/list_constructor.dart:11:7: Error: Can't use the default List constructor.
// Try using List.filled instead.
// new List<int>(42);
// ^
//
import self as self;
import "dart:core" as core;
static method foo<T extends core::Object? = core::Object?>() dynamic {
let final<BottomType> #t1 = invalid-expression "pkg/front_end/testcases/nnbd/list_constructor.dart:9:7: Error: Can't use the default List constructor.
Try using List.filled instead.
new List<T>(42);
^" in core::_List::•<self::foo::T%>(42);
let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/nnbd/list_constructor.dart:10:7: Error: Can't use the default List constructor.
Try using List.filled instead.
new List<int?>(42);
^" in core::_List::•<core::int?>(42);
let final<BottomType> #t3 = invalid-expression "pkg/front_end/testcases/nnbd/list_constructor.dart:11:7: Error: Can't use the default List constructor.
Try using List.filled instead.
new List<int>(42);
^" in core::_List::•<core::int>(42);
}
static method main() → dynamic {}