MSVC: Tolerate c_std_17 and c_std_23 features on older compiler versions

MSVC `cl` versions prior to 19.27 had no `-std:c*` flags for C
standards.  List the `c_std_{17,23}` features anyway.  This allows
projects to at least attempt compilation with these compilers since they
do not have any modes.
This commit is contained in:
Brad King
2021-10-28 12:18:42 -04:00
parent 22f804e0ec
commit 6561b032bc

View File

@ -49,6 +49,8 @@ else()
c_std_90
c_std_99
c_std_11
c_std_17
c_std_23
c_function_prototypes
)
list(APPEND CMAKE_C90_COMPILE_FEATURES c_std_90 c_function_prototypes)