New issue
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
Update for existing Check: LocalVariableName #23
Comments
Change to "Allow one character variable in for loops."
Change to "mAllowOneCharVarInForLoop
Should be "if(mAllowOneCharForLoopVar && isForLoopVariable(aAST)) {"
Change to "if a variable is the loop's one"
I think your logic won't work properly if there is a loop variable with multiple chars: for(int index = 1; index <10; index++) { Please add this case into your test input and check |
Also update the check's documentation and xdocs |
Done
Done
Done
Done
I have added this case (InputSimple) and UTs did't fall.
Done |
Change to "An example of how to configure the check to allow"
There are a lot of simular test inputs and they all cover the same case. Please remove redundant inputs and add the new ones you don't have:
Change to "The check provides the following properties:" |
Done
Done, see changes into InputSimple file
Done |
http://docs.oracle.com/javase/tutorial/java/nutsandbolts/for.html it is initialization expression - so call that you examine only initialization expression in a loop, and put this link to JavaDoc.
Why end of line symbol is missed in RegExp
|
|
you have two option so you need to describe all options and then provide examples . See how it is done in here - http://checkstyle.sourceforge.net/config_annotation.html
"in FOR loop", fix in all places. |
|
What does this mean ? do you catch expression like "(i)" |
|
please translate this and read carefully .... . And write me there example of this. Read attentively what is initialization expressions! |
xdoc have to be fixed too for that problem, users will read HTML description first. |
Was updated according to Javadoc in LocalVariableNameCheck |
ok PR. |
Update LocalVariableName to allow one-character for temporary and looping variables. http://google-styleguide.googlecode.com/svn/trunk/javaguide.html#s5.2.7-local-variable-names
The text was updated successfully, but these errors were encountered: