At 3:16 +0200 23/6/05, Waldek Hebisch wrote:
As I wrote I updated may implementation of Delphi classes to gpc-20050331. Now, I have put a patch at:
Sorry for the delay, it took me a while to get gpc compiling, convert over to using gp, install the patch and start converting my object code over to see how it goes.
I don't use the MAC_PASCAL dialect, so for the moment I hacked the diff to comment out the line:
// PNL if (co->pascal_dialect & MAC_PASCAL)
so that objects are always treated as Mac style objects (I imagine in the fullness of time there will be a compiler directive to control this independent of the dialect, but this seemed an easy solution to allow testing the patch.
dispose( self ) complains:
/Source/MyAssocStrings.p: In method `AssocStringsObject.Destroy': /Source/MyAssocStrings.p:254: error: argument 1 to `Dispose' must be a pointer
I turned on {$methods-always-virtual}
There needs to be a control over the "warning: object type has virtual method, but no constructor". Perhaps just methods-always-virtual disables that warning?
Currently it is giving me "error: undeclared identifier `MethodName'" when I try to call a method of the parent object (the parent object is all defined in one unit, and the child all in another unit). I will try to simplify the code causing the problem down to a simple test case.
Thanks, Peter.