When javac creates a synthetic field, it's initialization can be put before the super call. This means the resulting code throws a compile error, cause super must always be the first call.
Here is a bytecode example that illustrates this issue:
I'd propose just swapping the generated lines of code to ensure super(x) is always first. Not sure exactly how the code is generated, so this might not be as simple
CFR version
0.152-SNAPSHOT
Compiler
Unknown.
Description
When javac creates a synthetic field, it's initialization can be put before the
super
call. This means the resulting code throws a compile error, causesuper
must always be the first call. Here is a bytecode example that illustrates this issue:And the resulting java code is: