On Fri, 22 Sep 2023 19:44:00 GMT, Justin Lu <j...@openjdk.org> wrote:

>> test/jdk/java/util/Calendar/Bug4766302.java line 32:
>> 
>>> 30: import java.util.GregorianCalendar;
>>> 31: 
>>> 32: @SuppressWarnings("serial")
>> 
>> Is removing this OK?
>
> At first I thought so, there is no warning about a missing serialVersionUID 
> when the _SuppressWarnings_ annotation is removed, and IntelliJ actually 
> flags the annotation as redundant. But since it was added separately and 
> intentionally in [JDK-8165296](https://bugs.openjdk.org/browse/JDK-8165296), 
> I would rather leave it alone on second thought.

Not sure why IntelliJ claims it redundant, but compiling the test case alone, 
without that `@SuppressWarnings` with `-Xlint` gives me this:

warning: [serial] serializable class MyCalendar has no definition of 
serialVersionUID

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

PR Review Comment: https://git.openjdk.org/jdk/pull/15853#discussion_r1334788356

Reply via email to