From 0653933009414c665fc246c8256a3befc8073ffe Mon Sep 17 00:00:00 2001 From: roblabla Date: Fri, 4 Aug 2023 22:46:34 +0200 Subject: [PATCH] Don't pass wd4668 to clang-cl --- src/compiler/msvc.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/compiler/msvc.rs b/src/compiler/msvc.rs index e6474fd9d..248c9e195 100644 --- a/src/compiler/msvc.rs +++ b/src/compiler/msvc.rs @@ -885,9 +885,6 @@ where .args(&parsed_args.preprocessor_args) .args(&parsed_args.dependency_args) .args(&parsed_args.common_args) - // Windows SDK generates C4668 during preprocessing, but compiles fine. - // Read for more info: https://github.com/mozilla/sccache/issues/1725 - .arg("/wd4668") .env_clear() .envs(env_vars.iter().map(|(k, v)| (k, v))) .current_dir(cwd); @@ -902,6 +899,9 @@ where cmd.arg("/sourceDependencies"); cmd.arg(depfile); } + // Windows SDK generates C4668 during preprocessing, but compiles fine. + // Read for more info: https://github.com/mozilla/sccache/issues/1725 + cmd.arg("/wd4668"); } if rewrite_includes_only && is_clang {