Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

duplicate interface error



Hi,

I was trying to implement the NSCopying protocol for one of my classes, and the next time i compiled I got these two warnings/errors:

warning: duplicate interface declaration for class 'GenericRecord'
error: redefinition of 'struct GenericRecord'

The errors are cited within a file that imports the GenericRecord class.

The interface (and there is only one that I know of) looks harmless enough:

@interface GenericRecord : NSObject <NSCopying>
{
<<ivars>>
}
....
- (GenericRecord *) copyWithZone: (NSZone *) zone;

Earlier in the day XCode claimed that I had a duplicate "DataTypes.h" file (where I keep some enum definitions and functions). I removed the only visible one from the Groups & Files list (being sure to make a safe copy elsewhere of the contents elsewhere). Now things compile fine, but looking at Groups & Files it looks to me like the file ought to be considered missing.

There appears to be some kind of ghost in the machine, and I have no idea where to look. I was originally working with smaller programs from which some of these files were copied (copy reference and file when adding). But I don't see why this is suddenly a problem now and have no idea how to fix it.

Thanks in advance.

Daniel
_______________________________________________

Cocoa-dev mailing list (email@hidden)

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/email@hidden

This email sent to email@hidden


Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.