In Scala, method signature semantics goes beyond method name, parameters and result type. The signature can also tell about whether a method has side effects, or whether a method represents a property.
However, sometimes we forget about writing proper definitions or method calls. That’s where 15 new method signature inspections may help.
Method declaration syntax inspections
Method with Unit result type is parameterless:

Method with Unit result type defined with equals sign:

Method with Unit result type defined like function:

Redundant Unit result type annotation:

Apparent refinement of result type:

Method name inspections
Method with accessor-like name is empty-paren:

Method with accessor-like name has Unit result type:

Method with mutator-like name is parameterless:

Method overriding inspections
Empy-paren Scala method overriden as parameterless:

Parameterless Scala member overriden as empty-paren:

Java accessor method overriden as empty-paren:

Java mutator method overriden as parameterless:

Method access inspections
Empty-paren method accessed as parameterless:

Java accessor method called as empty-paren:

Java mutator method accessed as parameterless:

Inspections are one of my favorite features in IntelliJ and my experience with these Scala Inspections has been very positive. They go beyond what is possible in Java inspections because they talk to how you should use an API or whether or not a var is necessary. In effect these Inspections seriously help the team write idiomatic Scala code which is better for everyone
A penny saved is a penny got [earned].
It is appropriate time to make some plans for the future and it is time to be happy. I have read this post and if I could I desire to suggest you some interesting things or suggestions. Maybe you could write next articles referring to this article. I want to read even more things about it!
Sono pienamente d’accordo.
It is perfect time to make some plans for the future and it is time to be happy. I have read this post and if I could I wish to suggest you few interesting things or advice. Perhaps you can write next articles referring to this article. I wish to read more things about it!
100% Tested and guaranteed! read more