Two questions about parameter nullness in the JDK (original) (raw)
Michael Ernst mernst at cs.washington.edu
Mon Jun 2 02:40:03 UTC 2014
- Previous message: RFR [8037866] Replace the Fun class in tests with lambdas
- Next message: RFR for 8043740 (Doubles with large exponents overflow to Infinity incorrectly)
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
I have a couple of questions about places that the JDK is under-specified with respect to nullness properties.
Many GitHub projects pass null as the implVendor argument to ClassLoader.definePackage:
https://github.com/search?p=2&q=definePackage+packageName+null&ref=searchresults&type=Code
However, the ClassLoader.definePackage documentation does not say whether null is permitted or forbidden as an argument. Could you clarify and document this issue?
Another example is ClassFileTransformer.transform. It seems safe to pass in a null protectionDomain to the current implementation:
https://gist.github.com/trask/d47133aef3b662b6548b
However, the documentation does not explicitly state whether null is permitted or forbidden. I'd like to get a ruling on this issue so that it can be documented as well.
Thanks very much for your help!
-Mike
- Previous message: RFR [8037866] Replace the Fun class in tests with lambdas
- Next message: RFR for 8043740 (Doubles with large exponents overflow to Infinity incorrectly)
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]