expected_ one_ list_ type_ arguments
Details about the 'expected_one_list_type_arguments' diagnostic produced by the Dart analyzer.
List literals require one type argument or none, but {0} found.
Description
#The analyzer produces this diagnostic when a list literal has more than one type argument.
Example
#The following code produces this diagnostic because the list literal has two type arguments when it can have at most one:
var l = <int, int>[];
Common fixes
#Remove all except one of the type arguments:
var l = <int>[];
除非另有说明,文档之所提及适用于 Dart 3.12.2 版本报告页面问题.