My code is compiled using the g++ compiler version 4.9.0. I'm using C++11.
However, the compiler doesn't understand the nullptr
keyword. Here is what I've found out:
- This is not a typo, because the word
nullptr
is displayed in bold in the editor. - g++ supports
nullptr
, because its version is greater than 4.6.0. - The compiler understands that I want to use C++11, because it doesn't complain when I use
auto
ordecltype
one line earlier (I use the-std=c++0x
command-line argument, but I also the-std=gnu++0x
).
I have no idea what else can be wrong, so I'll be grateful for any suggestions.
Edit: the error message is the following:
error: nullptr was not declared in this scope.
This is the output of the g-- version command:
g++ (OSE 4.9.2-2 20160202) 4.9.2