Reputation: 43
Is there a way to limit the MSVC to only support c++11 features but not anything from c++14 or 17?
I am using MSVC++ 14.1 _MSC_VER == 1910 (Visual Studio 2017 version 15.0)
Thanks!
Upvotes: 1
Views: 1822
Reputation: 2663
I don't know what specific C++14/17 features are you trying to avoid but you can have a look at Microsoft's Support For C++11/14/17 Features (Modern C++) and select the version of Visual Studio whose feature set is closest to what you are seeking.
You can either use that version of Visual Studio or any later one since Visual Studio supports compilation with older toolsets provided you have them installed.
Upvotes: 0
Reputation: 72271
It doesn't appear so. MSVC's C++ compiler does have a /std
compiler option, but the documentation only says it can be used as /std:c++14
, /std:c++17
, or /std:c++latest
(to include some features from C++20 drafts).
However, there are not a lot of huge changes between C++11 and C++14, and many of them can be considered "fixes" to things that were inconvenient or just missing from C++11. So maybe /std:c++14
could be close enough for your purposes?
Upvotes: 1