[analyzer] ConvertToStateless
should consider non-constant fields
#50682
Labels
analyzer-assist
Issues with analysis server assists
area-analyzer
Use area-analyzer for Dart analyzer issues, including the analysis server and code completion.
P3
A lower priority bug or feature request
type-bug
Incorrect behavior (everything from a crash to more subtle misbehavior)
has an assist to convert it to
which gives a compile error, because
const
constructor conflicts with the non-constant field.In this case, it is better to also remove the
const
keyword. This would also lead to the necessity of the removal ofconst
in the construction invocation, but that's outside the scope of the assist.The text was updated successfully, but these errors were encountered: