Re: Using Objective-C object in C++ source
Re: Using Objective-C object in C++ source
- Subject: Re: Using Objective-C object in C++ source
- From: Shawn Erickson <email@hidden>
- Date: Thu, 14 May 2009 12:18:19 -0700
On Thu, May 14, 2009 at 11:44 AM, K. Chen <email@hidden> wrote:
> Does it mean I can write C++ code inside Objective-C program (with certain
> constraints) but not vice versa?
You can mix both ways if you compile your source as Objective-C++.
Review the link someone posted earlier for detail but...
- C++ classes found in Objective-C++ (.mm) source files are true C++
objects when compiled.
- Objective-C classes found in Objective-C++ (.mm) source files are
true Objective-C objects when compiled.
- Objective-C methods can call C++ methods, etc. if using Objective-C++
- C++ methods can send Objective-C messages, etc. if using Objective-C++
The issues are primarily in the realm of having C++ instance members
in Objective-C classes and exceptions.
-Shawn
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden