This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
If an interface that extends Serializable is defined, and a default method is written, then a hint to add a serialVersionUID may be displayed (if enabled). This is incorrect as a (private) serialVersionUID field cannot be defined in an interface. This does not occur on interfaces without default methods. For example: interface Blah extends java.io.Serializable { default int one() { return 1; } } The associated refactoring tries to modify this to the following, which does not compile: interface Blah extends java.io.Serializable { private static final long serialVersionUID = 1L; default int one() { return 1; } }
default java algorithm which computes serialVersionUID does not include interface methods when serializing a class. There are a couple of JDK bugs related to this feature: https://bugs.openjdk.java.net/browse/JDK-6356530 http://bugs.java.com/view_bug.do?bug_id=6368570 I will disable the warning, further changes may come based on the referenced bug resolution. Fixed in jet-main#c27ec1bc71ab
Integrated into 'main-silver', will be available in build *201407300001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main-silver/rev/c27ec1bc71ab User: Svata Dedic <sdedic@netbeans.org> Log: #245141: warning about serialversionuid in interface filtered out