I'm using Quartus 18.0 Std and the NIOS SBT for eclipse. I have a header file called util.hpp which should be treated as C++. But all C++ code in the header is flagged as a compiler error as in cpp_error1.jpg.
I decided to add an #ifdef __cplusplus fully expecting that section of code to gray out. Instead it now compiles as in cpp_error2.jpg.
I'm not sure what is going on here. The #ifdef seems to be causing to compile as C++ instead of just checking if it is C++.
Note, C++ code in a .cpp file in the same project compiles just fine. Also, showing the properties of the util.hpp shows it to be C++.