dtrebbien commented on issue #314: Add a new fix to BoxedIdentityComparison URL: https://github.com/apache/incubator-netbeans/pull/314#issuecomment-358019726 I have significantly overhauled the modifications to NPECheck, based on @sdedic's [concern](https://github.com/apache/incubator-netbeans/pull/314#discussion_r154876644) about the broad-scope heuristic that I was using in the previous iteration of this patch. There is now a user-configurable "nullability of fields" preference, which allows the user to customize which fields (identified by their fully-qualified name) would be considered null, non-null, or possibly null by NPECheck. This mechanism also allows for a set of base mappings, stored in `BASE_NULLABILITY_OF_FIELDS`, that are referred to if the user has not specifically configured a field. Right now, I have only added mappings for `java.lang.Boolean.TRUE` and `java.lang.Boolean.FALSE`, but I will add a lot more if you all like this new approach. I was also thinking about "nullability of method return values" which would allow the user to customize whether specifically-identified methods return null, non-null, or possibly null values. This will be slightly more complex to support than "nullability of fields", so I have not done this, but if you all like the "nullability of fields" idea, then I will certainly work on this extension.
---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: [email protected] With regards, Apache Git Services --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected] For further information about the NetBeans mailing lists, visit: https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists
