leibnitz27 / cfr

This is the public repository for the CFR Java decompiler
https://www.benf.org/other/cfr
MIT License
1.93k stars 249 forks source link

CFR hangs infinitely when trying to decompile a class with empty infinite loop. #261

Closed jaskarth closed 2 years ago

jaskarth commented 2 years ago

CFR version

0.151

Compiler

Javac 1.8.0_275

Description

CFR hangs infinitely when trying to decompile a class with empty infinite loops. Unfortunately, I've gotten into the bad habit of putting multiple decompiler test cases into the same class so I'm not sure which method causes it to break exactly 😅 Fun aside: Fernflower refused to decompile those first 4 methods at all before I patched it, as it removed redundant gotos and failed hard when it tried to stick a null statement into the method. I figured that I'd test CFR on it to see what it would do to compare, and here we are 😛

Example

Here's the source code and the class file.

leibnitz27 commented 2 years ago

Can't be having that ;) fortunately a pretty obvious one - cheers.