Asking for help in writing const and final linter rules #258
Unanswered
ivangalkindeveloper
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I'm asking for help in writing two linter rules
The question is how to parse the constant arguments of the initializer and whether the current initializer constructor is also const, since I have not yet found a way to do this
The question is: is it possible to determine references to a variable and understand whether this variable is subject to mutation? If not, recommend adding the keyword final
It seems to me that this rule is not implementable, since only the current file is analyzed, and I have not yet found ways in the package to determine the area where an current element may be present
I would be grateful for a code example with references to the necessary class properties to understand how these rules can be implemented
Beta Was this translation helpful? Give feedback.
All reactions