Skip to content

Commit

Permalink
downgrade types when getting descriptors/supertypes
Browse files Browse the repository at this point in the history
  • Loading branch information
wagyourtail committed May 23, 2024
1 parent fc70a55 commit 4f295f2
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -715,7 +715,7 @@ public Set<MemberNameAndDesc> apply(Type o) throws IOException {
members = new HashSet<>();
for (MethodNode method : ro.methods) {
if ((method.access & (Opcodes.ACC_ABSTRACT | Opcodes.ACC_PRIVATE)) != 0) continue;
members.add(new MemberNameAndDesc(method.name, Type.getMethodType(method.desc)));
members.add(new MemberNameAndDesc(method.name, downgrader.stubClass(ro.version, Type.getMethodType(method.desc))));
}
}
}
Expand All @@ -733,7 +733,7 @@ public List<Pair<Type, Boolean>> apply(Type o) throws IOException {
ClassNode ro = getReadOnly.apply(o.getInternalName());
if (ro != null) {
types = new ArrayList<>();
types.add(new Pair<>(Type.getObjectType(ro.superName), Boolean.FALSE));
types.add(new Pair<>(downgrader.stubClass(ro.version, Type.getObjectType(ro.superName)), Boolean.FALSE));
for (String anInterface : ro.interfaces) {
types.add(new Pair<>(Type.getObjectType(anInterface), Boolean.TRUE));
}
Expand Down

0 comments on commit 4f295f2

Please sign in to comment.