RFR: 8265130: Make ConstantDesc class hierarchy sealed [v2]

Mandy Chung mchung at openjdk.java.net
Thu May 20 23:43:31 UTC 2021


On Thu, 20 May 2021 22:35:38 GMT, Thiago Henrique Hüpner <github.com+13357965+Thihup at openjdk.org> wrote:

>> I should have made it clear.  I was expecting `DynamicConstantDesc` should be `sealed`.  Do you expect non-JDK implementation class extending `DynamicConstantDesc`?
>
> From the ConstantDesc Javadoc:
> 
>  * <p>Non-platform classes should not implement {@linkplain ConstantDesc} directly.
>  * Instead, they should extend {@link DynamicConstantDesc} (as {@link EnumDesc}
>  * and {@link VarHandleDesc} do.)

Thanks.  I missed this javadoc.

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

PR: https://git.openjdk.java.net/jdk/pull/4135


More information about the core-libs-dev mailing list