in Technology by (1.8m points)

Can I write some C++ function in same .m file? Will it compile? If no, what changes should I do to compile it?

1 Answer

0 votes
by (1.8m points)

The easiest solution is to simply tell Xcode to compile everything as Objective C++.

Set your project or target settings for Compile Sources As to Objective C++ and recompile.

Then you can use C++ or Objective C everywhere.

Related questions

0 votes
asked Nov 30, 2021 in Education by JackTerrance (1.8m points)