Pattern: Missing explicit variable type
Issue: -
Checks that variable types are explicitly specified in declarations (and not using def
).
Example of violations:
class MyClass {
void doStuff() {
final NAME = "joe" // violation
def count = 0, max = 99 // violation
def defaultName // violation
}
}