8334714: Implement JEP 484: Class-File API

Reviewed-by: liach, vromero
This commit is contained in:
Adam Sotona 2024-11-15 14:38:17 +00:00
parent 6cdebf0e4c
commit 84ffb64cd7
165 changed files with 312 additions and 799 deletions

View file

@ -32,14 +32,12 @@ import java.util.List;
import jdk.internal.classfile.impl.StackMapDecoder;
import jdk.internal.classfile.impl.TemporaryConstantPool;
import jdk.internal.javac.PreviewFeature;
/**
* Models stack map frame of {@code StackMapTable} attribute (JVMS {@jvms 4.7.4}).
*
* @since 22
* @since 24
*/
@PreviewFeature(feature = PreviewFeature.Feature.CLASSFILE_API)
public sealed interface StackMapFrameInfo
permits StackMapDecoder.StackMapFrameImpl {
@ -79,9 +77,8 @@ public sealed interface StackMapFrameInfo
/**
* The type of a stack value.
*
* @since 22
* @since 24
*/
@PreviewFeature(feature = PreviewFeature.Feature.CLASSFILE_API)
sealed interface VerificationTypeInfo {
/** The {@link #tag() tag} for verification type info {@link SimpleVerificationTypeInfo#TOP TOP}. */
@ -124,9 +121,8 @@ public sealed interface StackMapFrameInfo
/**
* A simple stack value.
*
* @since 22
* @since 24
*/
@PreviewFeature(feature = PreviewFeature.Feature.CLASSFILE_API)
public enum SimpleVerificationTypeInfo implements VerificationTypeInfo {
/** verification type top */
@ -166,9 +162,8 @@ public sealed interface StackMapFrameInfo
/**
* A stack value for an object type. Its {@link #tag() tag} is {@value #ITEM_OBJECT}.
*
* @since 22
* @since 24
*/
@PreviewFeature(feature = PreviewFeature.Feature.CLASSFILE_API)
sealed interface ObjectVerificationTypeInfo extends VerificationTypeInfo
permits StackMapDecoder.ObjectVerificationTypeInfoImpl {
@ -205,9 +200,8 @@ public sealed interface StackMapFrameInfo
/**
* An uninitialized stack value. Its {@link #tag() tag} is {@value #ITEM_UNINITIALIZED}.
*
* @since 22
* @since 24
*/
@PreviewFeature(feature = PreviewFeature.Feature.CLASSFILE_API)
sealed interface UninitializedVerificationTypeInfo extends VerificationTypeInfo
permits StackMapDecoder.UninitializedVerificationTypeInfoImpl {