Compilers are allowed to provide extensions and library functions which aren't part of the C++ standard they're targeting. While VC++ 2010 doesn't comply fully with the C++11 standard, it does support certain features which are in C++11 and aren't in C++98, such as auto
and static_assert
.
There's a certain amount of risk involved in using "forward-compatible" features like this, because the draft of the standard the compiler writers targeted might have changed after the compiler was released, but C++11 was getting pretty stable by 2010, and the specification of stoi
is almost certainly unchanged in the final standard from its implemention in VC++ 2010.
This page gives information on which VC++ versions support which C++11 features.