diff --git a/sootup.core/src/main/java/sootup/core/util/printer/JimplePrinter.java b/sootup.core/src/main/java/sootup/core/util/printer/JimplePrinter.java index 20842db752d..daf83dc9794 100644 --- a/sootup.core/src/main/java/sootup/core/util/printer/JimplePrinter.java +++ b/sootup.core/src/main/java/sootup/core/util/printer/JimplePrinter.java @@ -136,6 +136,10 @@ public void printTo(SootClass cl, PrintWriter out, LabeledStmtPrinter printer) { */ EnumSet modifiers = EnumSet.copyOf(cl.getModifiers()); + // Jimple parser in Soot gives error with super keyword in class modifiers + if (options.contains(Option.LegacyMode)) { + modifiers.remove(ClassModifier.SUPER); + } // remove unwanted modifier combinations if (cl.isInterface() && ClassModifier.isAbstract(modifiers)) { modifiers.remove(ClassModifier.ABSTRACT);