Inspectopedia Help

Lambda parameter type can be specified

Reports lambda parameters that do not have their type specified and suggests adding the missing type declarations.

Example:

Function<String, Integer> length = a -> a.length();

After the quick-fix is applied:

Function<String, Integer> length = (String a) -> a.length();

This inspection only reports if the language level of the project or module is 8 or higher.

Inspection Details

Available in:

IntelliJ IDEA 2023.3, Qodana for JVM 2023.3

Plugin:

Java, 233.SNAPSHOT

Last modified: 13 July 2023