@@ -276,12 +276,13 @@ impl Serialize for Value<'_> {
276276
277277///
278278pub mod path {
279- use crate :: values:: Path ;
279+ use std:: borrow:: Cow ;
280+
280281 #[ cfg( not( target_os = "windows" ) ) ]
281282 use pwd:: Passwd ;
282283 use quick_error:: ResultExt ;
283- use std :: borrow :: Cow ;
284- use std :: path :: PathBuf ;
284+
285+ use crate :: values :: Path ;
285286
286287 pub mod interpolate {
287288 use quick_error:: quick_error;
@@ -358,7 +359,7 @@ pub mod path {
358359
359360 #[ cfg( target_os = "windows" ) ]
360361 fn interpolate_user ( self ) -> Result < Cow < ' a , std:: path:: Path > , interpolate:: Error > {
361- Err ( interpolate:: ErrorUserInterpolationUnsupported )
362+ Err ( interpolate:: Error :: UserInterpolationUnsupported )
362363 }
363364
364365 #[ cfg( not( target_os = "windows" ) ) ]
@@ -376,15 +377,16 @@ pub mod path {
376377 . dir ;
377378 let path_past_user_prefix =
378379 git_features:: path:: from_byte_slice ( & path_with_leading_slash[ 1 ..] ) . context ( "path past ~user/" ) ?;
379- Ok ( PathBuf :: from ( home) . join ( path_past_user_prefix) . into ( ) )
380+ Ok ( std :: path :: PathBuf :: from ( home) . join ( path_past_user_prefix) . into ( ) )
380381 }
381382 }
382383
383384 #[ cfg( test) ]
384385 mod tests {
385- use crate :: values:: { path:: interpolate:: Error , Path } ;
386386 use std:: borrow:: Cow ;
387387
388+ use crate :: values:: { path:: interpolate:: Error , Path } ;
389+
388390 #[ test]
389391 fn not_interpolated ( ) {
390392 let path = & b"/foo/bar" [ ..] ;
@@ -460,7 +462,7 @@ pub mod path {
460462 fn user_interpolated ( ) {
461463 assert ! ( matches!(
462464 Path :: from( Cow :: Borrowed ( & b"~baz/foo/bar" [ ..] ) ) . interpolate( None ) ,
463- Err ( path:: interpolate:: ErrorUserInterpolationUnsupported )
465+ Err ( path:: interpolate:: Error :: UserInterpolationUnsupported )
464466 ) ) ;
465467 }
466468
0 commit comments