Skip navigation.
 
mlc++ in obj-c cocoa apps (post-FAQ)
FROM : Sean Gilbertson
DATE : Thu Oct 28 18:22:58 2004

I've read the section in the FAQ <http://www.alastairs-place.net/cocoa/faq.txt> on including C++ code in objective-C Cocoa apps, and I've also read what I can find on the net, but I still have some questions:

   - Is it feasible to include standard, no-complaints-from-gcc-on-the-commandline C++ code in Cocoa-oriented objective-c source files?  I get plenty of errors about everthing from syntax to not finding standard C++ includes (e.g. exception; string), which seem to indicate that the compiler is assuming the code is written in C rather than C++.
   - Can I compile a library of C++ classes separately, and use them in Cocoa-oriented objective-c code?
   - If I can't include the code as-is, is there some preferably trivial way I can alter it so that the compiler will like it?

--
Sean Gilbertson
IT Systems/Software Developer

Related mailsAuthorDate
mlc++ in obj-c cocoa apps (post-FAQ) Sean Gilbertson Oct 28, 18:22
mlRe: c++ in obj-c cocoa apps (post-FAQ) R. Scott Thompson Oct 28, 18:50