diff options
author | Nirbheek Chauhan <nirbheek@centricular.com> | 2020-09-11 15:20:27 +0530 |
---|---|---|
committer | Nirbheek Chauhan <nirbheek@centricular.com> | 2020-09-11 15:20:27 +0530 |
commit | d56d1b006e6b77eaa88b6f74c1de1324c3a08d8e (patch) | |
tree | 5a61727558721e87842a5912137694787e41a678 | |
parent | 008d13038f95e7c7d8ad553f14e408da5b94c360 (diff) | |
download | meson-d56d1b006e6b77eaa88b6f74c1de1324c3a08d8e.zip meson-d56d1b006e6b77eaa88b6f74c1de1324c3a08d8e.tar.gz meson-d56d1b006e6b77eaa88b6f74c1de1324c3a08d8e.tar.bz2 |
Revert "msvc: enable /std:c11 flag"
This reverts commit b5edb514d7e7a4a6852167bcccf57940ab245ccf, which
was not supposed to be cherry-picked to the stable branch.
It causes projects that were previously working and had c_std=gnu99 in
default_options to error out with:
```
meson.build:1:0: ERROR: Value "gnu99" for combo option "C language
standard to use" is not one of the choices. Possible choices are:
"none", "c89", "c99", "c11".
```
-rw-r--r-- | mesonbuild/compilers/c.py | 20 |
1 files changed, 0 insertions, 20 deletions
diff --git a/mesonbuild/compilers/c.py b/mesonbuild/compilers/c.py index 95851be..aac99b4 100644 --- a/mesonbuild/compilers/c.py +++ b/mesonbuild/compilers/c.py @@ -353,26 +353,6 @@ class VisualStudioCCompiler(MSVCCompiler, VisualStudioLikeCCompilerMixin, CCompi info, exe_wrap, **kwargs) MSVCCompiler.__init__(self, target) - def get_options(self): - opts = super().get_options() - c_stds = ['none', 'c89', 'c99', 'c11'] - opts.update({ - 'std': coredata.UserComboOption( - 'C language standard to use', - c_stds, - 'none', - ), - }) - return opts - - def get_option_compile_args(self, options): - args = [] - std = options['std'] - # As of MVSC 16.7, /std:c11 is the only valid C standard option. - if std.value in {'c11'}: - args.append('/std:' + std.value) - return args - class ClangClCCompiler(ClangClCompiler, VisualStudioLikeCCompilerMixin, CCompiler): def __init__(self, exelist, version, for_machine: MachineChoice, |