You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
➜ dartanalyzer main.dart
Analyzing main.dart...
No issues found!
➜ dart main.dart
Unhandled exception:
type 'MappedListIterable<String, String>' is not a subtype of type 'List<String>'
#0 main (file:///Users/means88/code/test/main.dart:12:22)
#1 _startIsolate.<anonymous closure> (dart:isolate/runtime/libisolate_patch.dart:289:19)
#2 _RawReceivePortImpl._handleMessage (dart:isolate/runtime/libisolate_patch.dart:171:12)
The text was updated successfully, but these errors were encountered:
Dart allows you to use values with a static type that is a supertypes of the type that is expected. The object is implicitly down-cast to the subtype. If you expect a List<int> and you provide an Iterable<int>, it is as if there is an implicit as List<int> added.
That cast can then fail at run-time.
Dart VM version: 2.1.0 (Tue Nov 13 18:22:02 2018 +0100) on "macos_x64"
dartanalyzer version 2.1.0
The text was updated successfully, but these errors were encountered: