A project with some Objective-C has a few C classes with the implementation files having a .mm extension.
file.h file.mm
What does the .mm mean? Shouldn't it just be .m?
Objective C files In objective C, files normally use the extension . h for interface files and the extension . m for implementation files.
mm are class file extensions of source code for Mac-based applications. . m files can contain both Objective-C and Objective-C++ classes. To avoid conflicts between the two in mixed-use scenarios there's the convention to rename all Objective-C++ class files to . mm . This helps compilers to distinguish.
An MM file contains a "mind map," which is a visual diagram that consists of text, nodes, branches, shapes, and icons that represent ideas. It may be created by a variety of "mind-mapping" programs, such as FreeMind and Freeplane.
The extension .mm
is the extension for the C++
compilation unit expected by the Objective-C compiler, while the .m
extension is the extension for the C
compilation unit expected by the Objective-C compiler.
That's assuming you don't use a compiler flag to override the file extension, as this gentleman has done.
Objective C++, mixes C++ and Objective C. http://en.wikipedia.org/wiki/Objective-C#Objective-C.2B.2B
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With