Rollup merge of #148963 - tshepang:patch-2, r=jieyouxu

runtest.rs: remove redundant check

The check is already done in enclosing code
This commit is contained in:
Stuart Cook 2025-11-16 14:40:03 +11:00 committed by GitHub
commit 34aef3a6a9
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -1635,8 +1635,7 @@ impl<'test> TestCx<'test> {
// executed and that don't specify their own optimization levels.
// Note: aux libs don't have a pass-mode, so they won't get optimized
// unless compile-flags are set in the aux file.
if self.config.optimize_tests
&& self.props.pass_mode(&self.config) == Some(PassMode::Run)
if self.props.pass_mode(&self.config) == Some(PassMode::Run)
&& !self
.props
.compile_flags