925e3fe782
This change adds the ability to detect when one branch of a conditional expression is weak-only due to nullability. For example, in the following code: int f(int/*!*/ i) => i == null ? g(null) : i; int g(int j) => ...; the call to `g` can only happen in weak checking mode. The migrator also now understands that j only needs to be nullable if i is nullable. Fixes #41555. Partially addresses #41551. Bug: https://github.com/dart-lang/sdk/issues/41555 Change-Id: I02c9c3072f0104db0f1a5b432fb1f2f8f06d5282 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/144120 Reviewed-by: Mike Fairhurst <mfairhurst@google.com>