Description
The Dart language now allows Future<void>
, and the type of dart:io RandomAccessFile.close() has been changed to that in commit
44aa9a17fd8ca5278dfe12590ad48212fefda4dd
Future<void> close();
instead of
Future<RandomAccessFile> close();
This causes a crash in line 176 of src/element_type.dart, where f.element.library is tested against null, to special-case A<dynamic>
. But with A<void>
, f.element
is itself null. If we change to f.element?.library != null
, we get a crash in the call to ModelElement.from(f.element, lib)
, again, where there is special casing for dynamic, but not for void.
Flutter code is being changed to use Future<void>
, and this IO change should also land, so we need to handle this case.
Reverting 44aa9a17fd8ca5278dfe12590ad48212fefda4dd until this is fixed and rolled to Dart SDK
The builder with the failure is:
https://ci.chromium.org/buildbot/client.dart/dart-sdk-linux-be/19230
@jcollins-g
@jcollins-g: edited to escape types