site_archiver@lists.apple.com Delivered-To: darwin-dev@lists.apple.com
The C++ standard, ISO/IEC 14882 (2003), does not say anything about the names of source files. This is left up to implementations.
The GCC compiler accepts a number of extensions, including .cc, .cpp, and .cxx. There's no reason, other than personal preference or your organization's coding standards, to prefer one over another. (I do recommend against using .C, though. It's fine as far as GCC is concerned, but it interacts poorly with case-insensitive file systems.)
My bad, you are correct. Thank you for noticing this. I pointed out that I am not positive this was a part of the standard. The .cpp is however a common extension agreed upon by almost everyone. It's what both Mozilla requires (http://www.mozilla.org/hacking/portable-cpp.html#file_extension_is_cpp) and what would Microsoft IDE make for you. If fact every place I worked for last few years had .cpp as a standard extension. The Apple Darwin sources are all .cpp just the same. _______________________________________________ Do not post admin requests to the list. They will be ignored. Darwin-dev mailing list (Darwin-dev@lists.apple.com) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/darwin-dev/site_archiver%40lists.appl... This email sent to site_archiver@lists.apple.com
participants (1)
-
Igor Shmukler