when I test the __cplusplus version in the .cpp, keil uvison shows the correct one
But, when I test it in the h. file, keil uvison doesn't show the same version as in .cpp .
code:
#if (__cplusplus < 201103L) #define MY_TEST_H 0 // greyed out in .cpp file #endif #if (__cplusplus >= 201103L) #define YOUR_TEST_H 11 // greyed out in .h file #endif