General Articles and Tutorials

C++ language standard compliance

Author: Alexander Stoyan
Platform: Visual C++ MFC

Starting from version 20.0 ToolkitPro respects the highest possible code quality demands allowed by the supported MSVC compilers, those include:

  1. Full support of ISO C++14 language standard (compiler switch /std:c++14)
  2. Full support of ISO C++17 language standard (compiler switch /std:c++17)
  3. Full support of enforced and relaxed C++ language standard conformance modes (compiler switches /permissive- and /permissive)
  4. Full support of all warning levels (compiler switches /W0, /W1, /W2, /W3, /W4, /Wall)
  5. Successful compilation of all combinations of the mentioned above modes with treating warnings as errors (compiler switch /WX)

Starting from version 20.0 every new ToolkitPro release will ensure strict C++ language standard compliance only for MSVC compier versions versions available at the time of the ToolkitPro release. The newer MSVC compiler versions may introduce new validations or may break backward compatibility thus introducing new warnings or potentially even compilation errors in ToolkitPro.

The /std:c++latest compiler switch that is assumed to enable all the latest available features supported by the compiler is not and will never be supported by ToolkitPro as it is an experimental mode and according to Microsoft it may break backward compatibility:

The compiler and library features enabled by /std:c++latest represent features that may appear in a future C++ standard, as well as C++20 features that are approved. Features that have not been approved are subject to breaking changes or removal without notice and are provided on an as-is basis.

Codejock does not recommend using /std:c++latest in the production code.