Commit Graph

7 Commits

Author SHA1 Message Date
Raul Tambre
95bc11dbb4 MSVC: Record support for c_static_assert
Supported since MSVC 19.28.29115 (VS 16.8.0 Preview 1.0).
2020-08-20 09:45:47 -04:00
Raul Tambre
f7347f28c7 MSVC: Record support for C11 and c_restrict
MSVC >=19.27 supports a C11 switch.
The `c_restrict` feature has also been implemented.

Fixes: #21069
2020-08-11 09:08:21 -04:00
Hanjiang Yu
f6f4eb0907 clang-tidy: Add driver mode argument
`clang-tidy` does not infer driver mode if it is not provided with a
JSON compilation database.  This is exactly the way cmake launches it.
Hence clang-tidy will only use the default driver mode.  Add an explicit
driver mode argument to avoid this.
2020-01-27 13:59:05 -05:00
Luca Cappa
2a9ff9703e MSVC: Add support for /JMC (Just My Code) 2019-05-14 13:27:18 -04:00
Brad King
eca275f63d CompileFeatures: Fix hard-coded MSVC C features
In commit 8e4899fd6c (CompileFeatures: Record which C features the MSVC
compiler supports, 2019-04-12) our `cmake_record_c_compile_features`
macro was accidentally left not setting the `_result` variable, which
had previously been set by `_record_compiler_features`.  The variable is
expected by the call site in `cmake_determine_compile_features` and used
to switch between "failed" and "done" reports.  Set it now.

Also record `c_variadic_macros` only for cl 14 (VS 2005) and higher
because it is not supported before that version.
2019-04-22 08:22:54 -04:00
Robert Maynard
8e4899fd6c CompileFeatures: Record which C features the MSVC compiler supports
Use the infrastructure added by commit f92ccbc306
(CompileFeatures: memoize C compilers with full language level support)
to avoid using a `try_compile` to check for C 90/99/11 feature support when the running compiler is known to have a fixed set of feature support.
2019-04-12 14:39:57 -04:00
Brad King
a53cf69022 Features: Record C features for MSVC
The MSVC C compiler has no notion of C language standards or flags.
Tell CMake to assume that all language standards are available.
Record available C language features depending on the version of
the compiler.

Fixes: #17858
2018-03-29 10:40:13 -04:00