You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I attempt to decompile a bytecode program with fairly simple (but impossible in Java) control flow. CFR outputs a Java program but includes a note 'Unable to fully structure code'. I got to this example while investigating another issue #359 that I assume is related. It seems to me that it should be possible to restructure this code for decompilation, although this is of course an atypical program!
And the error from CFR is Unable to fully structure code. It cannot structure the code corresponding to block_2, which has two entry points (from block_0 and block_1).
/*
* Decompiled with CFR 0.153-SNAPSHOT (3d1d0f4).
*/
public class TestCase {
/*
* Unable to fully structure code
*/
public void testCase(int[] var1_1) {
var2_2 = 0;
if (var2_2 == 0) ** GOTO lbl-1000
block4: while (true) {
switch (var2_2) {
case 0: {
continue block4;
}
case 1: lbl-1000:
// 3 sources
{
while (var2_2 != 0) {
}
break block4;
}
}
break;
}
}
}
CFR version
CFR 0.153-SNAPSHOT (3d1d0f4)
Compiler
openjdk 19.0.2
Description
I attempt to decompile a bytecode program with fairly simple (but impossible in Java) control flow. CFR outputs a Java program but includes a note 'Unable to fully structure code'. I got to this example while investigating another issue #359 that I assume is related. It seems to me that it should be possible to restructure this code for decompilation, although this is of course an atypical program!
The bytecode program looks like this:
And the error from CFR is
Unable to fully structure code
. It cannot structure the code corresponding toblock_2
, which has two entry points (fromblock_0
andblock_1
).Example
example.zip
I attach the following:
program.j
which is the original bytecode fileTestCase.class
which is the class file associated withprogram.j
TestCase.java
which is the decompiled output of CFRThe text was updated successfully, but these errors were encountered: