diff options
| author | Jussi Pakkanen <jussi.pakkanen@mailbox.org> | 2025-11-10 11:48:06 +0200 |
|---|---|---|
| committer | Jussi Pakkanen <jussi.pakkanen@mailbox.org> | 2025-11-23 16:04:33 +0200 |
| commit | c52e6c92b08d28048047fa5642f16530bc81c5d7 (patch) | |
| tree | 0f6001cfd92eb0c7a65ded81818f85a9242f352c /mesonbuild/compilers/cpp.py | |
| parent | 35193dd8e4f2a24ae689eeb8d01a2c3bcca11025 (diff) | |
| download | meson-c52e6c92b08d28048047fa5642f16530bc81c5d7.tar.gz | |
Add import std support to MSVC.
Diffstat (limited to 'mesonbuild/compilers/cpp.py')
| -rw-r--r-- | mesonbuild/compilers/cpp.py | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/mesonbuild/compilers/cpp.py b/mesonbuild/compilers/cpp.py index 908d6dc45..bdf60f6c2 100644 --- a/mesonbuild/compilers/cpp.py +++ b/mesonbuild/compilers/cpp.py @@ -801,6 +801,13 @@ class VisualStudioLikeCPPCompilerMixin(CompilerMixinBase): std_opt = opts[self.form_compileropt_key('std')] assert isinstance(std_opt, options.UserStdOption), 'for mypy' std_opt.set_versions(cpp_stds) + + if version_compare(self.version, '>=19.44.35219'): + key = self.form_compileropt_key('importstd') + opts[key] = options.UserComboOption(self.make_option_name(key), + 'Use #import std.', + 'false', + choices=['false', 'true']) return opts def get_option_compile_args(self, target: 'BuildTarget', subproject: T.Optional[str] = None) -> T.List[str]: |
