summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexey Telishev <alex-telishev@ya.ru>2022-05-08 17:06:05 +0300
committerGitHub <noreply@github.com>2022-05-08 16:06:05 +0200
commite8aef251aa0947ad1f238d80070d39f4e05074d8 (patch)
treeed7c51678635f9015a5456b945e0fa93795c767a
parent16c493657671a7bb6b82776f6ad2f5682afdad91 (diff)
downloadccache-e8aef251aa0947ad1f238d80070d39f4e05074d8.tar.gz
fix: Fix "Multiple precompiled headers used" error if /Yu option is used after /Fp (#1059)
-rw-r--r--src/argprocessing.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/argprocessing.cpp b/src/argprocessing.cpp
index 6d362669..a0888b2b 100644
--- a/src/argprocessing.cpp
+++ b/src/argprocessing.cpp
@@ -125,6 +125,7 @@ detect_pch(const std::string& option,
if (state.found_valid_Fp) { // Use file set by -Fp.
LOG("Detected use of precompiled header: {}", included_pch_file);
pch_file = included_pch_file;
+ included_pch_file.clear(); // reset pch file set from /Fp
} else {
std::string file = Util::change_extension(arg, ".pch");
if (Stat::stat(file)) {