I am running Code::Blocks version Code::Blocks 13.12 on Windows 7 HP
(version OperatingSystemVersionNumber). The compiler I use is TDM-GCC
version 4.7.1.
Description of problem.
My .cpp files fail to compile. When I google the errors, it seems that the program uses C compiler. In the build log it also uses the C compiler. I saved all my files as .cpp but to no avail. I went to check my compiler .exe for g++ and it is there (mingw32-g++.exe).
Build log:
mingw32-gcc.exe -Wall -fexceptions -g -c "C:\Users\Benedict\Desktop\Chapter 9 Ex1\C9E4\namespace.h" -o namespace.h.gch
C:\Users\Drakonaut\Desktop\Chapter 9 Ex1\C9E4\namespace.h:4:1: error: unknown type name 'namespace'
C:\Users\Drakonaut\Desktop\Chapter 9 Ex1\C9E4\namespace.h:5:1: error: expected '=', ',', ';', 'asm' or '__attribute__' before '{' token
I have already tried googling for answers but none seemed to work (Maybe I'm not trying hard enough or am missing some keywords).
EDIT: Nvm, I've found a way to do it (Changing the CC to CPP in the properties file.)