35e6c16c9c
Simplifies the logic and makes it more robust, after: https://dart-review.googlesource.com/c/sdk/+/99090 Bug: https://github.com/dart-lang/sdk/issues/36047 Change-Id: Ic7e6ef8f7bf5da930f8e2ce3cc712d992ad26652 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/99201 Reviewed-by: Alexander Markov <alexmarkov@google.com> Commit-Queue: Liam Appelbe <liama@google.com>