Fix implementation of resends to allow relaxed
restrictions on arguments to resends. See
!FIXME!resend in source code.
Currently we restrict resends to the Cecil 'resend;'
sugar semantics. If we allow changing of arguments in
non-specialized positions then we need to have wrapper
methods to get at the overridden method that is
targetted by the resend. Some variant of the following
example is pertinent:
public void Object.foo(Object o1) { }
public class Sup {
// the following belong to external GF foo
// and will be placed in an inner dispatcher class
public void foo(Object o1) { }
public void foo(Object@String s1) { }
}
public class Sub extends Sup {
public void foo(Object o1) {
resend("hi"); // must target Sup.foo(Object@String)
}
}
I wrote the following in an email discussion last Sept.
related to this:
Option 1: We could conceivable relax the privileged
access restrictions on the generated ident$body methods
to permit the resends to directly target the directly
overridden methods, bypassing any dispatching code. We
might need some wrapper methods in the outer classes of
dispatcher classes in the o-e2 case. This should be
workable but essentially admits no changes to the
superclass (or external generic function declaration)
without recompiling the code containing the resend.
Perhaps this is not so bad given how narrowly targeted
resends are.