-
Enhancement
-
Resolution: Cannot Reproduce
-
P4
-
9.0.4
-
generic
-
generic
A DESCRIPTION OF THE REQUEST :
Currently if a user provides a lambda that does not have a return value when one is expected gets this kind of error message:
required: java.util.function.Function<? super java.util.List<Key, Value>,? extends U>
found: (currencyP[...]}); }
reason: cannot infer type-variable(s) U
(argument mismatch; bad return type in lambda expression
missing return value)
You are essentially burying the lead. Please don't make users read through multiple lines of ugly Generics code when they don't have to.
The error message should read something along the lines of:
Expected a return value but none was found.
required : X
found: Y
reason: Z
JUSTIFICATION :
Improve readability, ease of debugging
Currently if a user provides a lambda that does not have a return value when one is expected gets this kind of error message:
required: java.util.function.Function<? super java.util.List<Key, Value>,? extends U>
found: (currencyP[...]}); }
reason: cannot infer type-variable(s) U
(argument mismatch; bad return type in lambda expression
missing return value)
You are essentially burying the lead. Please don't make users read through multiple lines of ugly Generics code when they don't have to.
The error message should read something along the lines of:
Expected a return value but none was found.
required : X
found: Y
reason: Z
JUSTIFICATION :
Improve readability, ease of debugging