[fpc-pascal] Inherited and not virtual/overridden procedures

Bart bartjunk64 at gmail.com
Thu Jun 13 00:13:25 CEST 2013


On 6/12/13, Jonas Maebe <jonas.maebe at elis.ugent.be> wrote:

> Now change the variable type to TFoo but keep instantiating it using
> TFooChild.Create (like I originally suggested). Having that work is
> the whole point of polymorphism and why virtual/override exist.

I didn't even know that was possible....

OK now I see the difference.
Not making them virtual/ovverride the shows only TFoo.Bar, whilst
making them virtual/override shows the TFooChild.Bar implementation.

Bart



More information about the fpc-pascal mailing list