'round' is not a member of 'std'
c++, g++
Solution
The `std::round` functions are C++11, so you would need to compile with C++11 or a more recent standard enabled.
Problem
I'm try to compile this code: ``` #include <cmath> double gravity (double level) { return 0.02 * std::round(level); } ``` But GCC is telling me: ``` error: 'round' is not a member of 'std' ``` I know I've used the `round` function many times in ISO C++98 before. Unusually, `round` and `::round` both work. What gives? Update: I was compiling with `g++ -std=c++98 -Wall -pedantic`. Switching to `std=c++0x` works. But why do the unqualified/anonymous `round` and `::round` both work if `std::round` doesn't?