TICS Coding Standard Viewer 
TIOBE Software Quality Framework
Print-friendly version
©TIOBE Software www.tiobe.com
 
TIOBE - Java Coding Standard
Search

Rule:  Basic14Checked automatically with code checker

Synopsis:Avoid unnecessary return statements
Language:Java
Severity Level:3
Category:Basic


Description:
Avoid unnecessary return statements in methods with return type void.
public class Foo {
    public void bar() {
        int x = 42;
        return;
    }
}