mirror of
https://github.com/dart-lang/sdk
synced 2024-09-05 00:13:50 +00:00
[analyzer] Consolidate more helpers in evaluation_test.
Added helpers `_field` and `_localVar` to allow tests to test their final fields and local const variables in the const tests. The rest of the CL moves away from `_evaluateConstant` helpers (to avoid recomputing constants), to `_topLevelVar` or equivalent helpers which grabs the existing evaluation result. This CL adds to the goal making all constant tests consistent and to avoid unnecessary const computations in the tests. Change-Id: I508483714a51e5d060286256657ae460b65787c7 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/312889 Reviewed-by: Nate Bosch <nbosch@google.com> Commit-Queue: Kallen Tu <kallentu@google.com> Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
This commit is contained in:
parent
3daa47b54e
commit
c7187d3150