Hello list,

I have a linking error that is puzzling me and I'd be grateful for some enlightenment.

In AppDelegate.h:

#import "SharedDefs.h"

In AppDelegate.m:

#import "AppDelegate.h"
#import "SomeClass.h"

In SomeClass.m:

#import "SomeClass.h"
#import "SharedDefs.h"

SharedDefs.h contains definitions (#define's, struct's and enum's) that are shared by several classes.

This works fine until I add

NSString* const someString = @"foo";

to SharedDefs.h, at which point I get a duplicate symbol linking error for _someString.

What gives?

Thanks in advance.
Wagner
_______________________________________________

Cocoa-dev mailing list ([email protected])

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 [email protected]

Reply via email to