You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[analyzer] Avoid call from one visit method to another in resolver.
When `PrefixedIdentifierResolver.resolve` rewrites a prefixed
identifier expression to a property access (which it does when the
prefix is an expression having record type), instead of making a call
from `ResolverVisitor.visitPropertyAccess` to
`ResolverVisitor.visitPropertyAccess` to resolve the rewritten
expression, use a private helper method for both code paths.
This ensures that all `visit` methods in the `ResolverVisitor` are
called solely from `ExpressionImpl.accept` or from
`ExpressionImpl.resolveExpression` (at least as far as expressions are
concerned). This will pave the way for a follow-up CL, in which I will
make sure that all expression resolution is done through the
`TypeAnalyzer.analyzeExpression` method. That will in turn allow the
analyzer to use the shared implementation of null-shorting introduced
in https://dart-review.googlesource.com/c/sdk/+/399480.
Change-Id: I782e10be2f58fdc0991b6d917f81bedd856485a9
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/399627
Reviewed-by: Brian Wilkerson <[email protected]>
Commit-Queue: Paul Berry <[email protected]>
0 commit comments