2024-06-06 13:47:00 -05:00
|
|
|
use std::iter;
|
2024-03-23 09:48:44 -05:00
|
|
|
use std::path::Path;
|
|
|
|
|
2024-07-17 08:31:38 -05:00
|
|
|
use run_make_support::{rfs, rustdoc};
|
2024-07-28 17:13:50 -05:00
|
|
|
|
2024-03-23 09:48:44 -05:00
|
|
|
fn generate_a_lot_of_cfgs(path: &Path) {
|
|
|
|
let content = iter::repeat("--cfg=a\n").take(100_000).collect::<String>();
|
2024-07-17 07:42:06 -05:00
|
|
|
rfs::write(path, content.as_bytes());
|
2024-03-23 09:48:44 -05:00
|
|
|
}
|
|
|
|
|
|
|
|
fn main() {
|
2024-06-06 14:34:34 -05:00
|
|
|
let arg_file = Path::new("args");
|
2024-03-23 09:48:44 -05:00
|
|
|
generate_a_lot_of_cfgs(&arg_file);
|
|
|
|
|
2024-06-06 14:34:34 -05:00
|
|
|
rustdoc().input("foo.rs").arg_file(&arg_file).arg("--test").run();
|
2024-03-23 09:48:44 -05:00
|
|
|
}
|