Declared or not?
Declared or not?
- Subject: Declared or not?
- From: "Peter Karlsson" <email@hidden>
- Date: Wed, 26 Mar 2003 15:06:23 +0000
Dear list!
My interface file looks like this:
----------
@interface DataManager : NSObject
{
@private
Byte **partmidi_ptr;
}
+ (id) singletonInstance;
- (int) getPartmidi_ptr;
- (void) setPartmidi_ptr:(int) value;
@end
----------
And my implementation file looks like this:
----------
#import "DataManager.h"
@implementation DataManager
+ (id) singletonInstance
{
static id sharedDataManager = nil;
if (sharedDataManager == nil)
{
sharedDataManager = [[self alloc] init];
}
return sharedDataManager;
}
- (int) getPartmidi_ptr
{
return **partmidi_ptr;
}
- (void) setPartmidi_ptr:(int) value
{
**partmidi_ptr = value;
}
@end
----------
But this line (located in another file) generates an error, `partmidi_ptr'
undeclared, why? I declared it in my interface file...
if((partmidi_ptr = malloc(sizeof(*partmidi_ptr) * 1024)) == NULL)
Peter
_________________________________________________________________
STOP MORE SPAM with the new MSN 8 and get 2 months FREE*
http://join.msn.com/?page=features/junkmail
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.