Chromium Code Reviews
DescriptionStop precomputing ClassElement.isValidMixin.
Previously, we would precompute the value of ClassElement.isValidMixin
and store it in the Modifier.MIXIN. But this didn't really save any
time, because (a) isValidMixin isn't used inside analyzer, and (b) it
is easily derivable from other information already present in the
element model.
Also, we were computing it incorrectly when the `--supermixin` flag
was present.
This CL replaces the precomputation logic with a direct implementation
in ClassElement.isValidMixin which is correct regardless of the
presence of the `--supermixin` flag. The tests are beefed up so that
(a) they validate correct behavior for both states of the flag, (b)
they validate correct behavior in the presence of factory
constructors, and (c) they validate that the behavior of
`isValidMixin` is consistent with the error messages produced by the
analyzer.
In addition to fixing bugs, the removal of Modifier.MIXIN means we
have one less piece of information to store in summaries.
R=brianwilkerson@google.com
Committed: https://github.com/dart-lang/sdk/commit/4e86a006db963f3e335734202abcc02a2ea7e705
Patch Set 1 #
Total comments: 4
Messages
Total messages: 8 (2 generated)
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||