runtest: correctly guard against LLVM version 13

This commit is contained in:
Augie Fackler
2021-05-17 13:08:42 -04:00
parent f429ab3c18
commit 3035816fc1
+5 -1
View File
@@ -2293,7 +2293,11 @@ fn verify_with_filecheck(&self, output: &Path) -> ProcRes {
// For now, though…
if let Some(rev) = self.revision {
let prefixes = format!("CHECK,{}", rev);
filecheck.args(&["--allow-unused-prefixes", "--check-prefixes", &prefixes]);
if self.config.llvm_version.unwrap_or(0) >= 130000 {
filecheck.args(&["--allow-unused-prefixes", "--check-prefixes", &prefixes]);
} else {
filecheck.args(&["--check-prefixes", &prefixes]);
}
}
self.compose_and_run(filecheck, "", None, None)
}