File tree Expand file tree Collapse file tree 3 files changed +13
-9
lines changed
Expand file tree Collapse file tree 3 files changed +13
-9
lines changed Original file line number Diff line number Diff line change @@ -26,9 +26,10 @@ fn main() {
2626 codegen_backend_arg. push ( cg_clif_dylib_path) ;
2727 args. push ( codegen_backend_arg) ;
2828 }
29- if !passed_args. iter ( ) . any ( |arg| {
30- arg == "--sysroot" || arg. to_str ( ) . is_some_and ( |s| s. starts_with ( "--sysroot=" ) )
31- } ) {
29+ if !passed_args
30+ . iter ( )
31+ . any ( |arg| arg == "--sysroot" || arg. to_str ( ) . is_some_and ( |s| s. starts_with ( "--sysroot=" ) ) )
32+ {
3233 args. push ( OsString :: from ( "--sysroot" ) ) ;
3334 args. push ( OsString :: from ( sysroot. to_str ( ) . unwrap ( ) ) ) ;
3435 }
Original file line number Diff line number Diff line change @@ -26,12 +26,18 @@ fn main() {
2626 codegen_backend_arg. push ( cg_clif_dylib_path) ;
2727 args. push ( codegen_backend_arg) ;
2828 }
29- if !passed_args. iter ( ) . any ( |arg| {
30- arg == "--sysroot" || arg. to_str ( ) . is_some_and ( |s| s. starts_with ( "--sysroot=" ) )
31- } ) {
29+ if !passed_args
30+ . iter ( )
31+ . any ( |arg| arg == "--sysroot" || arg. to_str ( ) . is_some_and ( |s| s. starts_with ( "--sysroot=" ) ) )
32+ {
3233 args. push ( OsString :: from ( "--sysroot" ) ) ;
3334 args. push ( OsString :: from ( sysroot. to_str ( ) . unwrap ( ) ) ) ;
3435 }
36+ if passed_args. is_empty ( ) {
37+ // Don't pass any arguments when the user didn't pass any arguments
38+ // either to ensure the help message is shown.
39+ args. clear ( ) ;
40+ }
3541 args. extend ( passed_args) ;
3642
3743 let rustdoc = if let Some ( rustdoc) = option_env ! ( "RUSTDOC" ) {
Original file line number Diff line number Diff line change @@ -99,9 +99,6 @@ rm tests/ui/mir/mir_raw_fat_ptr.rs # same
9999rm tests/ui/consts/issue-33537.rs # same
100100rm tests/ui/consts/const-mut-refs-crate.rs # same
101101
102- # rustdoc-clif passes extra args, suppressing the help message when no args are passed
103- rm -r tests/run-make/issue-88756-default-output
104-
105102# doesn't work due to the way the rustc test suite is invoked.
106103# should work when using ./x.py test the way it is intended
107104# ============================================================
You can’t perform that action at this time.
0 commit comments