We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
==
!=
equals()
!equals()
Bugs like this: #8326 could be caught on the static analysis level, using Regex patterns (Checkstyle Regexp) or Structural search inspection.
Example of regex which should have caught #8326: (?m)return ([^\;]+)(this\.)?([a-zA-Z]+) \!\= [a-zA-Z]+\.\1
(?m)return ([^\;]+)(this\.)?([a-zA-Z]+) \!\= [a-zA-Z]+\.\1
Similar regexes could be created for equals(), Object.equals(), as well as incorrect use in
Object.equals()
if (x != that.x) { return false; }
code in equals() implementations.
The text was updated successfully, but these errors were encountered:
Successfully merging a pull request may close this issue.
Bugs like this: #8326 could be caught on the static analysis level, using Regex patterns (Checkstyle Regexp) or Structural search inspection.
Example of regex which should have caught #8326:
(?m)return ([^\;]+)(this\.)?([a-zA-Z]+) \!\= [a-zA-Z]+\.\1
Similar regexes could be created for
equals()
,Object.equals()
, as well as incorrect use incode in
equals()
implementations.The text was updated successfully, but these errors were encountered: