File tree Expand file tree Collapse file tree 1 file changed +6
-7
lines changed
tests/run-make/issue-11908 Expand file tree Collapse file tree 1 file changed +6
-7
lines changed Original file line number Diff line number Diff line change 1313
1414use run_make_support:: { rustc, dynamic_lib, tmp_dir} ;
1515use std:: fs;
16- use std:: path:: PathBuf ;
1716
1817fn main ( ) {
1918 let mut tmp_dir_other = tmp_dir ( ) ;
2019 tmp_dir_other. push ( "other" ) ;
2120
22- fs:: create_dir ( tmp_dir_other) ;
21+ fs:: create_dir ( tmp_dir_other. clone ( ) ) ;
2322 rustc ( ) . input ( "foo.rs" )
2423 . crate_type ( "dylib" )
2524 . codegen_option ( "prefer-dynamic" )
2625 . run ( ) ;
27- fs:: rename ( dynamic_lib ( "foo" ) , tmp_dir_other) ;
26+ fs:: rename ( dynamic_lib ( "foo" ) , tmp_dir_other. clone ( ) ) ;
2827 rustc ( ) . input ( "foo.rs" )
2928 . crate_type ( "dylib" )
3029 . codegen_option ( "prefer-dynamic" )
3130 . run ( ) ;
3231 rustc ( ) . input ( "bar.rs" )
33- . library_search_path ( tmp_dir_other)
32+ . library_search_path ( tmp_dir_other. clone ( ) )
3433 . run ( ) ;
3534 fs:: remove_dir_all ( tmp_dir ( ) ) ;
3635
37- fs:: create_dir_all ( tmp_dir_other) ;
36+ fs:: create_dir_all ( tmp_dir_other. clone ( ) ) ;
3837 rustc ( ) . input ( "foo.rs" )
3938 . crate_type ( "rlib" )
4039 . run ( ) ;
4140 let mut tmp_dir_libfoo = tmp_dir ( ) ;
4241 tmp_dir_libfoo. push ( "libfoo.rlib" ) ;
43- fs:: rename ( tmp_dir_libfoo, tmp_dir_other) ;
42+ fs:: rename ( tmp_dir_libfoo, tmp_dir_other. clone ( ) ) ;
4443 rustc ( ) . input ( "foo.rs" )
4544 . crate_type ( "rlib" )
4645 . run ( ) ;
4746 rustc ( ) . input ( "bar.rs" )
48- . library_search_path ( tmp_dir_other)
47+ . library_search_path ( tmp_dir_other. clone ( ) )
4948 . run ( ) ;
5049}
You can’t perform that action at this time.
0 commit comments