Visual Studio 2010 compiling .cpp files as .c files
I'm working one a Visual Studio solution which was generated using CMake (not sure 开发者_如何转开发if this is relevant).
In this solution there a c file, I wanted to change it into a cpp file, so I renamed it and changed the extension.
However, Visual Studio still treats it like a c file and gives compiler errors whenever I add any c++ style code.
I'm stuck, any advice would be much appreciated.
Project Properties, Configuration, C/C++, Advanced, change "Compile As".
精彩评论