-
Notifications
You must be signed in to change notification settings - Fork 12.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Migrate
run-make/inline-always-many-cgu
to rmake.rs
- Loading branch information
1 parent
d9962bb
commit e7dfd4a
Showing
3 changed files
with
18 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
use run_make_support::fs_wrapper::read_to_string; | ||
use run_make_support::regex::Regex; | ||
use run_make_support::{read_dir, rustc}; | ||
|
||
use std::ffi::OsStr; | ||
|
||
fn main() { | ||
rustc().input("foo.rs").emit("llvm-ir").codegen_units(2).run(); | ||
let re = Regex::new(r"\bcall\b").unwrap(); | ||
let mut nb_ll = 0; | ||
read_dir(".", |path| { | ||
if path.is_file() && path.extension().is_some_and(|ext| ext == OsStr::new("ll")) { | ||
assert!(!re.is_match(&read_to_string(path))); | ||
nb_ll += 1; | ||
} | ||
}); | ||
assert!(nb_ll > 0); | ||
} |