We hope to fix this problem in the first release following 1.2fcs.
Given the lack of a specification to back this up, I'm concerned that
there might be some unanticipated compatibility fallout. I think we
should defer this to an upgrade release, in which there will be a
formal beta-test period.
Miranda methods should not be needed when compiling for a 1.2VM.
We should simply make sure that -target 1.2 suppresses them, and move
away from them altogether. Given that Miranda methods are obsolete,
it seems inappropriate to risk compatibility problems at this time.
Miranda methods are not synthetic methods in the same sense as those
generate by inner classes. It is true that Miranda methods are added
to classes that do not declare them, and are explicitly represented
in the class file where they a method would otherwise need not appear,
but they are just an implementation device for methods that actually are
declared by the user in an inherited interface, and which, conceptually,
do belong to the affected class, by inheritance. The synthetic members
generated by inner classes, in contrast, bear no connection to any
method explicitly declared by the user.
In 1.4.2, we will be making Miranda methods synthetic to fix a number
of bugs in which their presence was affecting semantic analysis.
Because Miranda methods are only generated in -target 1.1,
and -target 1.2 is the default, this will
not affect the output of the compiler by default.
In -target 1.1 mode, the compiler generates an abstract method
definition for each method of an abstract class
that is inherited from an interface
in the implements clause of the class but is not implemented by
the class. This was originally done to help work around a bug
in an early VM, and has since been maintained for backward
compatibility. We call these "Miranda" methods. Because the
default is now "-target 1.2", these are not usually seen in the
class files generated by javac.
We continue to generate Miranda methods with -target 1.1, but
starting with J2SE 1.4.2 these methods are marked "Synthetic"
in the class file.