Skip to content

Commit

Permalink
Ignore C4668 when preprocessing MSVC
Browse files Browse the repository at this point in the history
  • Loading branch information
Alexei-Barnes committed Apr 13, 2023
1 parent 0af46b1 commit 0592bc0
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/compiler/msvc.rs
Original file line number Diff line number Diff line change
Expand Up @@ -913,6 +913,10 @@ 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.
// Making sure that 4668 is a level 4 warning prevents failing preprocessing on it.
// Read for more info: https://github.com/mozilla/sccache/issues/1725
.arg("/w44668")
.env_clear()
.envs(env_vars.iter().map(|&(ref k, ref v)| (k, v)))
.current_dir(cwd);
Expand Down

0 comments on commit 0592bc0

Please sign in to comment.