SpongePowered / Mixin

Mixin is a trait/mixin and bytecode weaving framework for Java using ASM
MIT License
1.37k stars 185 forks source link

Copy try-catch blocks when merging static initializers #644

Open DaMatrix opened 10 months ago

DaMatrix commented 10 months ago

Without this change, merged exception handler code is unreachable, as the try-catch block start/end/handler information isn't copied into the target method.

This also causes the merged method to work as expected if the target method contains more than one RETURN instruction.