@tgamblin is right, but here is a workaround:
class A{ public void some(){ sharedCode() } public final void someFromSuper(){ sharedCode() } private void sharedCode() {
Create a second version of your method in A that is final (not redefined) and will call it from C.
This is a really bad design, but sometimes it is needed and used inside the JDK itself.
Regards, StΓ©phane
source share