add inner class aw processing, make generic error gui scrollable
All checks were successful
Publish to snapshot maven / build (push) Successful in 18s

This commit is contained in:
moehreag 2024-06-11 23:42:04 +02:00
parent cf4996e1ff
commit fe32ccd2bd
2 changed files with 15 additions and 1 deletions

View file

@ -271,7 +271,7 @@ public class LoaderGui {
throwable.printStackTrace(new PrintWriter(writer)); throwable.printStackTrace(new PrintWriter(writer));
error.setText(writer.toString()); error.setText(writer.toString());
pane.add(error); pane.add(new JScrollPane(error));
frame.add(pane); frame.add(pane);
}); });

View file

@ -91,6 +91,20 @@ public class AccessWidener {
} }
return super.visitMethod(access, name, descriptor, signature, exceptions); return super.visitMethod(access, name, descriptor, signature, exceptions);
} }
@Override
public void visitInnerClass(String name, String outerName, String innerName, int access) {
Entry e = classMap.get(name);
if (e != null) {
access &= ~(Opcodes.ACC_PRIVATE | Opcodes.ACC_PROTECTED | Opcodes.ACC_PUBLIC);
access |= e.type.access;
}
if (fields.containsKey(name) || methods.containsKey(name) || mutations.containsKey(name)) {
access &= ~(Opcodes.ACC_PRIVATE | Opcodes.ACC_PROTECTED | Opcodes.ACC_PUBLIC);
access |= Opcodes.ACC_PUBLIC;
}
super.visitInnerClass(name, outerName, innerName, access);
}
}; };
reader.accept(mapper, 0); reader.accept(mapper, 0);