Waldek Hebisch wrote:
I have updated my class patch to gpc-2005031. Testing I get failure with fjf903c.pas:
TEST fjf903c.pas: /pom/kompi/gcc/tst44/gcc-3.4.3/gcc/p/test/fjf903c.pas:14: error: method `p', overrides parent method /pom/kompi/gcc/tst44/gcc-3.4.3/gcc/p/test/fjf903c.pas: In main program: /pom/kompi/gcc/tst44/gcc-3.4.3/gcc/p/test/fjf903c.pas:31: error: assignment from incompatible pointer type
And the question now: what happens if the child tries to make a method with the same name as a parent, but without `override'. Is it an error (like OOP) or maybe just "shadows" parent method?
In BP OOP it shadows. (It doesn't have `override', or if you will, it's implicit.)
But fjf903c.pas is `--mac-pascal', and AFAIK it needs override (right, Peter?), so the test program seems to be wrong without `override'.
Frank