diff --git a/build_system/tests.rs b/build_system/tests.rs index 2131b88c2328..738a76ef4c55 100644 --- a/build_system/tests.rs +++ b/build_system/tests.rs @@ -548,7 +548,8 @@ impl TestRunner { let host_compiler = Compiler::clif_with_triple(&dirs, host_triple); let mut target_compiler = Compiler::clif_with_triple(&dirs, target_triple); - target_compiler.rustflags = rustflags; + target_compiler.rustflags = rustflags.clone(); + target_compiler.rustdocflags = rustflags; target_compiler.runner = runner; Self { is_native, jit_supported, dirs, host_compiler, target_compiler }