C++ extensions

I was reading a book about C++ and it clearly states that windows
is not case sensitive about .cpp or .CPP, but Unix and Linux are.
Is it true that to make my programs more compatible to all OS,
should I make the extensions .CPP in the future and not .cpp anymore?

Same for .c to .C

Is it better to rename extensions to uppercase?
Last edited on
The convention I've seen pretty much everywhere I've done Linux development is to use lower case. So use .c and .cpp .

I'm sure other people's experiences may differ, though.
man gcc wrote:
file.c
C source code that must be preprocessed.

file.cc
file.cp
file.cxx
file.cpp
file.CPP
file.c++
file.C
C++ source code that must be preprocessed.

Topic archived. No new replies allowed.