RFR: 8313403: Remove unused 'mask' field from JFormattedTextField
Sergey Bylokhov
serb at openjdk.org
Tue Aug 1 03:49:58 UTC 2023
On Mon, 31 Jul 2023 10:26:44 GMT, Alexey Ivanov <aivanov at openjdk.org> wrote:
> The private field `mask` is never used in `JFormattedTextField`.
>
> I couldn't find any usages of the field, including JNI. Therefore, it is safe to remove.
It was left there since the JFormattedTextField class is Serializable, and it is a kind of "public" API because it is mentioned in the serializable form of this class(I think so). See an example where I had to add the spec to the private fields via CSR: https://bugs.openjdk.org/browse/JDK-8252544
But the JFormattedTextField is part of the Swing where we intentionally added a statement "Serialized objects of this class will not be compatible with future Swing releases" So we can delete it but probably CSR will be needed, I am not sure.
-------------
PR Comment: https://git.openjdk.org/jdk/pull/15088#issuecomment-1659520041
More information about the client-libs-dev
mailing list