File tree Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -53,7 +53,7 @@ fn strip_verbatim_from_prefix(prefix: &PrefixComponent<'_>) -> Option<PathBuf> {
5353#[ derive( Debug ) ]
5454struct RemoveError {
5555 kind : std:: io:: ErrorKind ,
56- path : String ,
56+ path : PathBuf ,
5757}
5858
5959impl std:: error:: Error for RemoveError { }
@@ -62,7 +62,8 @@ impl std::fmt::Display for RemoveError {
6262 fn fmt ( & self , f : & mut std:: fmt:: Formatter < ' _ > ) -> std:: fmt:: Result {
6363 f. write_fmt ( format_args ! (
6464 "failed to remove '{}' : {:?}" ,
65- self . path, self . kind
65+ self . path. display( ) ,
66+ self . kind
6667 ) )
6768 }
6869}
@@ -72,7 +73,7 @@ pub(crate) fn improve_remove_error(error: std::io::Error, path: &Path) -> std::i
7273 error. kind ( ) ,
7374 RemoveError {
7475 kind : error. kind ( ) ,
75- path : path. display ( ) . to_string ( ) ,
76+ path : path. to_path_buf ( ) ,
7677 } ,
7778 )
7879}
You can’t perform that action at this time.
0 commit comments