Checks for: (1) An if statements where both the if and else blocks contain only a single return statement with a constant or literal value. (2) When the second-to-last statement in a block is an if statement with no else, where the block contains a single return statement, and the last statement in the block is a return statement, and both return statements return a constant or literal value. This checks can be disabled by setting checkLastStatementImplicitElse to false.
Type | Name and description |
---|---|
Class |
astVisitorClass |
boolean |
checkLastStatementImplicitElse |
String |
name |
int |
priority |