RFR: 8299513: Cleanup java.io [v5]

Roger Riggs rriggs at openjdk.org
Tue Jan 10 15:01:57 UTC 2023


On Tue, 10 Jan 2023 13:34:49 GMT, Per Minborg <pminborg at openjdk.org> wrote:

>> Code in java.io contains many legacy constructs and semantics not recommended including: 
>> 
>> * C-style array declaration 
>> * Unnecessary visibility 
>> * Redundant keywords in interfaces (e.g. public, static) 
>> * Non-standard naming for constants 
>> * Javadoc typos 
>> * Missing final declaration 
>> 
>> These should be fixed as a sanity effort.
>
> Per Minborg has updated the pull request incrementally with one additional commit since the last revision:
> 
>   Revert removal of a final keyword

src/java.base/share/classes/java/io/ObjectStreamConstants.java line 38:

> 36:      * Magic number that is written to the stream header.
> 37:      */
> 38:     short STREAM_MAGIC = (short)0xaced;

I'd prefer to retain the `static`, it is easier to read and not have to remember that this declaration is in an interface.

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

PR: https://git.openjdk.org/jdk/pull/11848


More information about the core-libs-dev mailing list