Upgrade to ASM master (including early support for Java 23 bytecode)
Closes gh-31929
This commit is contained in:
parent
243ec88e95
commit
174eae377f
|
|
@ -194,7 +194,7 @@ public class ClassReader {
|
||||||
this.b = classFileBuffer;
|
this.b = classFileBuffer;
|
||||||
// Check the class' major_version. This field is after the magic and minor_version fields, which
|
// Check the class' major_version. This field is after the magic and minor_version fields, which
|
||||||
// use 4 and 2 bytes respectively.
|
// use 4 and 2 bytes respectively.
|
||||||
if (checkClassVersion && readShort(classFileOffset + 6) > Opcodes.V22) {
|
if (checkClassVersion && readShort(classFileOffset + 6) > Opcodes.V23) {
|
||||||
throw new IllegalArgumentException(
|
throw new IllegalArgumentException(
|
||||||
"Unsupported class file major version " + readShort(classFileOffset + 6));
|
"Unsupported class file major version " + readShort(classFileOffset + 6));
|
||||||
}
|
}
|
||||||
|
|
@ -1495,10 +1495,7 @@ public class ClassReader {
|
||||||
// Visit the RuntimeInvisibleParameterAnnotations attribute.
|
// Visit the RuntimeInvisibleParameterAnnotations attribute.
|
||||||
if (runtimeInvisibleParameterAnnotationsOffset != 0) {
|
if (runtimeInvisibleParameterAnnotationsOffset != 0) {
|
||||||
readParameterAnnotations(
|
readParameterAnnotations(
|
||||||
methodVisitor,
|
methodVisitor, context, runtimeInvisibleParameterAnnotationsOffset, /* visible= */ false);
|
||||||
context,
|
|
||||||
runtimeInvisibleParameterAnnotationsOffset,
|
|
||||||
/* visible = */ false);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// Visit the non standard attributes.
|
// Visit the non standard attributes.
|
||||||
|
|
|
||||||
|
|
@ -287,6 +287,7 @@ public interface Opcodes {
|
||||||
int V20 = 0 << 16 | 64;
|
int V20 = 0 << 16 | 64;
|
||||||
int V21 = 0 << 16 | 65;
|
int V21 = 0 << 16 | 65;
|
||||||
int V22 = 0 << 16 | 66;
|
int V22 = 0 << 16 | 66;
|
||||||
|
int V23 = 0 << 16 | 67;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Version flag indicating that the class is using 'preview' features.
|
* Version flag indicating that the class is using 'preview' features.
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue