File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
src/librustdoc/html/render Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -446,13 +446,13 @@ impl CratesIndexPart {
446446 /// Might return parts that are duplicate with ones in prexisting index.html
447447 fn get ( crate_name : & str , external_crates : & [ String ] ) -> Result < PartsAndLocations < Self > , Error > {
448448 let mut ret = PartsAndLocations :: default ( ) ;
449- let path = PathBuf :: from ( "index.html" ) ;
449+ let path = Path :: new ( "index.html" ) ;
450450 for crate_name in external_crates. iter ( ) . map ( |s| s. as_str ( ) ) . chain ( once ( crate_name) ) {
451451 let part = format ! (
452452 "<li><a href=\" {trailing_slash}index.html\" >{crate_name}</a></li>" ,
453453 trailing_slash = ensure_trailing_slash( crate_name) ,
454454 ) ;
455- ret. push ( path. clone ( ) , part) ;
455+ ret. push ( path. to_path_buf ( ) , part) ;
456456 }
457457 Ok ( ret)
458458 }
You can’t perform that action at this time.
0 commit comments