34b30f4371
Changes the signature of the following flow analysis methods: - `cascadeExpression_end` - `nullAwareAccess_rightBegin` so that they return an `ExpressionInfo`, which the caller is responsible for storing. Also changes `cascadeExpression_afterTarget` so that it no longer passes the return value from `_nullAwareAccess_rightBegin` to `_storeExpressionInfo`. This is unnecessary because the target of a cascade is never be used as an argument to `_getExpressionInfo`. Finally, changes the call sites of `nullAwareAccess_end` that do not have to do with cascades, so that they are responsible for clearing out the full expression info (by calling `storeExpressionInfo(wholeExpression, null)`. This was previously done by `nullAwareAccess_end` itself. (This is not necessary for cascades because in cascades, the call to `nullAwareAccess_end` is always followed by a call to `cascadeExpression_end`, and the caller stores the expression info after *that* call). Note that since one of the callers to `storeExpressionInfo` is now in `NullShortingMixin` (which only has access to flow analysis via the abstract base class `FlowAnalysisNullShortingInterface`), the abstract declaration of `storeExpressionInfo` had to be moved from `FlowAnalysis` to `FlowAnalysisNullShortingInterface`. Change-Id: I6a6a696472bb914d408346b1ec8c264f6bc5f63f Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/475160 Commit-Queue: Paul Berry <paulberry@google.com> Reviewed-by: Chloe Stefantsova <cstefantsova@google.com>