SDK issue #54002 is a breaking change request about a change to the
rules about the type function `UP`. This CL serves as a preparation
for landing the tool changes that are the topic of #54002. It changes
a few conditional expressions such that one branch gets an explicit
type based on an `as` expression, which means that the code has the
same semantics as before the change, but now it will compile without
errors both before and after the change in #54002 has been landed.
Change-Id: Iddc99c1c184c1f36744d089c15c5cf29aea699df
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/337780
Commit-Queue: Erik Ernst <eernst@google.com>
Reviewed-by: Lasse Nielsen <lrn@google.com>