RFR: 6185110: Undefined behaviour of SampleModel for width, height < 0
Phil Race
prr at openjdk.org
Thu Oct 16 19:22:42 UTC 2025
On Thu, 16 Oct 2025 18:26:32 GMT, Sergey Bylokhov <serb at openjdk.org> wrote:
> > This because if it isn't an exception in the method signature (as in foo() throws BarException), and instead you only have "@throws BarException" it will not be inherited.
>
> May be it is better to add them to the "@throws" list instead of duplicating the spec?
That would not help. In fact it makes it harder.
RuntimeExceptions aren't inherited in the method signature so I'd need to add them there in the subclass anyway in addition to what I am already doing with the @throws.
Then I'd feel obliged to change lots of similar things to be consistent and this is already big enough.
-------------
PR Comment: https://git.openjdk.org/jdk/pull/27754#issuecomment-3412518256
More information about the client-libs-dev
mailing list