From 5252996a4b6959550fc2a2508838200a52e5e261 Mon Sep 17 00:00:00 2001 From: volodya-lombrozo Date: Fri, 7 Jun 2024 14:44:36 +0300 Subject: [PATCH] feat(#268): remove the crutch related to InnerClasses attributes --- .../opeo/decompilation/FormattingDecompiler.java | 14 +------------- 1 file changed, 1 insertion(+), 13 deletions(-) diff --git a/src/main/java/org/eolang/opeo/decompilation/FormattingDecompiler.java b/src/main/java/org/eolang/opeo/decompilation/FormattingDecompiler.java index c0d079b7..62f1d39f 100644 --- a/src/main/java/org/eolang/opeo/decompilation/FormattingDecompiler.java +++ b/src/main/java/org/eolang/opeo/decompilation/FormattingDecompiler.java @@ -113,26 +113,14 @@ private XmirEntry format(final XmirEntry entry) { * The crutch should be removed after the original problem that requires * the crutch is fixed. * You can read more about the problem here: https://github.com/objectionary/eo/issues/3189 - * @todo #226:30min Remove the crutch related to InnerClass. - * The crutch is used to fix the problem with incorrect XMIR generated by jeo-maven-plugin. - * It removes the name attribute from the InnerClass elements. - * The crutch should be removed after the original problem is fixed: - * https://github.com/objectionary/jeo-maven-plugin/issues/605 */ private static XML format(final XML input) { final Directives lines = new Directives() .xpath( "//o[@name='descriptor' or @name='visible' or (@base and not(@line) and not(@abstract))]" ).attr("line", "999"); - final Directives inner = new Directives() - .xpath("//o[@name='InnerClass']") - .attr("base", "InnerClass") - .xpath("//o[@name='InnerClass']/@name") - .remove(); return new XMLDocument( - new Xembler(inner).applyQuietly( - new Xembler(lines).applyQuietly(input.node()) - ) + new Xembler(lines).applyQuietly(input.node()) ); } }