javassist
javassist copied to clipboard
Add "insertAfterLocalVariable" method on CtBehavior
The purpose of this method is to make changes to code where the line number or variable name is unknown or does not exist. I use it for some obfuscated code, but it doesn't work for all obfuscated code. For unobfuscated code it obviously works. The implementation is included with a test.
Good Day, @chibash. I don't know if I was able to fully understand the example you showed me, I hope the test I wrote is enough.
For example,
void foo(int x) { int y; do { int z; bar(x, y, z); } while (expr); : }
Thank you, Átila César.