On 01/15/11 10:30, Andrew Haines wrote: > On 01/14/11 14:38, Torsten Bonde Christiansen wrote: >> Hi List. >> >> Is it possible to jump a couple of levels in the inherited hierarchy >> when calling "inherited" on a method? >> >> > > I *think* I've done this before this way but test it to make sure it works: > > procedure TC.DoSomething: > begin > (Self as TA).DoSomething; > end; >
Okay I tested that and it didn't work. Does TC.DoSomething do anything other than call inherited from TA? If not then the following would work TC = class(TA) procedure DoSomething; override; end; .. procedure TC.DoSomething; assembler; nostackframe; asm jmp TA.DoSomething end; _______________________________________________ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-pascal