<Swing Dev> RFR: 5015261: JInternalFrame causes NPE [v3]

Phil Race prr at openjdk.java.net
Sat Aug 14 22:40:29 UTC 2021


On Sat, 14 Aug 2021 22:15:53 GMT, Sergey Bylokhov <serb at openjdk.org> wrote:

> > Folks who are doing it are likely seeing random exceptions anyway at a later time !
> 
> What we will do if the field will be set to null directly? Throw NPE at any point later when we will found null?

The field is protected. If a subclasser wants to destroy the functionality of a class they are subclassing there are lots of ways they can do that. Just add advisory doc on the protected field too.

-------------

PR: https://git.openjdk.java.net/jdk/pull/4989


More information about the swing-dev mailing list