Closed
Description
It looks like the runtime errors are not thrown synchronously, and with Chrome the test ends before throwing the exception.
I'm not sure if the test needs asyncStart
/asyncEnd
or this is a dart2wasm issue.
Minimal repro:
import 'dart:async';
class Derived<T> implements Future<T> {
noSuchMethod(Invocation invocation) => super.noSuchMethod(invocation);
}
test() async {
// flatten(Derived<int>) = int
Future<int> x = (() async => new Derived<int>())();
}
main() {
test();
}
This fails with a runtime error in d8, but passes in Chrome.