mirror of
https://github.com/dart-lang/sdk
synced 2024-11-02 14:32:24 +00:00
8e0feb9fa9
Currently we have to do a runtime `as FutureOr<T>` check for the parameter to `_Future<T>.asyncComplete(FutureOr<T> value)`. Although needed for general cases, for the particular usage in the VM's async/await transformer, we know that the test is going to suceed. This CL adds two VM-specific methods on `_Future` that take `dynamic` and downcast via `unsafeCast<>()` to avoid this rather large runtime type checking overhead. Issue https://github.com/dart-lang/sdk/issues/48226 TEST=ci Change-Id: Ieeffae3ac8e2960f849512cf22c51d41cadb1ecf Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/230261 Reviewed-by: Slava Egorov <vegorov@google.com> Reviewed-by: Lasse Nielsen <lrn@google.com> Commit-Queue: Martin Kustermann <kustermann@google.com> |
||
---|---|---|
.. | ||
bin | ||
lib | ||
test | ||
testcases/transformations | ||
tool | ||
analysis_options.yaml | ||
LICENSE | ||
pubspec.yaml | ||
README.md |
This package hosts VM specific Dart code and helper scripts.