JDK-8235220 - Java Issue Tracker
0x00000007aaba9268 java/lang/String 0x00000007aaba92a0 java/lang/String 0x00000007aaba9478 java/lang/String Error: java.lang.NullPointerException java.lang ...
0x00000007aaba9268 java/lang/String 0x00000007aaba92a0 java/lang/String 0x00000007aaba9478 java/lang/String Error: java.lang.NullPointerException java.lang ...
Java Oracle Java is the #1 programming language and development platform. It reduces costs, shortens development timeframes, drives innovation, and improves application services. Java continues to be the development platform of choice for enterprises and developers.
A DESCRIPTION OF THE PROBLEM : When providing a lambda function into a constructor that has a custom consumer interface as a parameter, compiler throws an assertion error. STEPS TO FOLLOW TO REPRODUCE THE PROBLEM : Compile provided source code.
Following example shows that if Long.MAX_VALUE is used as a parameter for this constructor then this constructor creates object with less then 1970 year in the string representation. Here is the example
addAttachment(String contentType, InputStream in). Because I don't know what type of InputStream that can be passed in, I can't use any of the provided DataSource implementation classes (e.g. java.activation.FileDataSource).
I understand that it is an error to overload a method with an other one with the same signature but a totally different return type. But it���s not clear to me why we are not allowed to change the return type in this particular case, since Integer is a subclass of Number.