On Wed, 26 May 2010 13:54:17 +0100, Joanna Carter said: >> A subclass ivar is apparently overwriting a super class ivar. >> When an instance of MGS_B sets stderrData the super class ivar >tempFilePath gets overwritten. > >I'm not sure what you mean here by "overwrite". > >@interface Base : NSObject >{ > @private > int i; >} > >@end > >@interface Sub : Base >{ > @private > int i; >} > >@end > >This code demonstrates what I would understand by overwriting, and it >fails to compile. Although, it should be possible to redeclare such >private ivars, it certainly is in C# and Delphi.
Joanna, I think you are confusing some similar-sounding words: override and overwrite (and there's also overload). By overwrite, he means the memory occupied by one ivar is being unexpectedly written to when writing to a different ivar. -- ____________________________________________________________ Sean McBride, B. Eng s...@rogue-research.com Rogue Research www.rogue-research.com Mac Software Developer Montréal, Québec, Canada _______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com