RE: error when calling function in another C file
RE: error when calling function in another C file
- Subject: RE: error when calling function in another C file
- From: "Navneet Kumar" <email@hidden>
- Date: Wed, 2 Jan 2008 17:40:23 +0530
Hi, thnks for the reply.
Actually I'm doing-
-(id)init
{
[super init];
Response = [[NSMutableArray alloc] init];
MyCFunc(response);
return self;
}
Still the error...
-----Original Message-----
From: cocoa-dev-bounces+navneet=email@hidden
[mailto:cocoa-dev-bounces+navneet=email@hidden] On Behalf
Of Navneet Kumar
Sent: Wednesday, January 02, 2008 3:35 PM
To: Cocoa-dev
Subject: error when calling function in another C file
Hi,
In my sample app, I'm calling a function from another C file as follows:
MyCFile.h:-
Int Func(CFMutableArrayRef response);
SampleApp.h:-
#include "MyCFile.h"
@interface SampleApp: NSObject
{
NSMutableArray *response;
}
SampleApp.m:-
#import "SampleApp.h"
@implementation SampleApp
-(id)init
{
[super init];
MyCFunc(response);
return self;
}
Build succeeds without any warning or error.
Documents say that NSMutableArray * and CFArrayRef are toll-free bridged.
And can be supplied as arguments to function interchangeably.
Running the program opens the assembly like code in debugger, with
objc_msgSend_rtp at the top of the stack and something related to _CFArray
downwards.
What I may be doing wrong?
Thanks in advance.
Navneet
_______________________________________________
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:
This email sent to email@hidden
_______________________________________________
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:
This email sent to email@hidden