Re: eval?
Re: eval?
- Subject: Re: eval?
- From: Louis-Philippe <email@hidden>
- Date: Mon, 31 May 2010 16:56:56 -0400
Thanks!
That's what I thought,
2010/5/31 Jens Alfke <email@hidden>
>
> On May 31, 2010, at 10:11 AM, Louis-Philippe wrote:
>
> > like, if I have a c++ lib I would like to call from within an Objective-c
> > class, assuming a call like:
>
> I’m not sure what it is you’re trying to do. You can easily call C++ code
> from Objective-C just by switching the compiler dialect to Objective-C++,
> which is done most simply by changing your source file’s extension from .m
> to .mm.
>
> If you’re trying to load a dylib dynamically and resolve symbols, use
> dlopen etc. as Sherm said. To call those functions you’ll need to cast the
> pointer to the appropriate type of function pointer and call it.
>
> If you’re looking for a general-purpose eval( ) function as found in
> interpreted languages like PHP or Python, there isn’t one. Objective-C is
> not an interpreted language, so the parsing and compilation is done at build
> time by the compiler, not at runtime.
>
> —Jens
_______________________________________________
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
References: | |
| >eval? (From: Louis-Philippe <email@hidden>) |
| >Re: eval? (From: Jens Alfke <email@hidden>) |