File tree Expand file tree Collapse file tree 2 files changed +9
-9
lines changed
Expand file tree Collapse file tree 2 files changed +9
-9
lines changed Original file line number Diff line number Diff line change @@ -350,14 +350,14 @@ impl Load for Fragment<'_> {
350350 fn load < P : AsRef < Path > > ( path : P ) -> Result < Self , Self :: Error > {
351351 let path = path. as_ref ( ) ;
352352
353- let name = path_name ( path) . ok_or_else ( || Error :: new_invalid_utf8 ( path. to_owned ( ) ) ) ?;
353+ let name = path_name ( path) . ok_or_else ( || Self :: Error :: new_invalid_utf8 ( path. to_owned ( ) ) ) ?;
354354
355355 let info = name
356356 . parse ( )
357- . map_err ( |error| Error :: parse ( error, path. to_owned ( ) ) ) ?;
357+ . map_err ( |error| Self :: Error :: parse ( error, path. to_owned ( ) ) ) ?;
358358
359359 let content = read_to_string ( path)
360- . map_err ( |error| Error :: new_read ( error, path. to_owned ( ) ) ) ?
360+ . map_err ( |error| Self :: Error :: new_read ( error, path. to_owned ( ) ) ) ?
361361 . trim ( )
362362 . to_owned ( ) ;
363363
Original file line number Diff line number Diff line change @@ -116,10 +116,10 @@ impl Load for Workspace<'_> {
116116 let path = path. as_ref ( ) ;
117117
118118 let string =
119- read_to_string ( path) . map_err ( |error| Error :: new_read ( error, path. to_owned ( ) ) ) ?;
119+ read_to_string ( path) . map_err ( |error| Self :: Error :: new_read ( error, path. to_owned ( ) ) ) ?;
120120
121- let workspace =
122- toml :: from_str ( & string ) . map_err ( |error| Error :: new_parse ( error, path. to_owned ( ) ) ) ?;
121+ let workspace = toml :: from_str ( & string )
122+ . map_err ( |error| Self :: Error :: new_parse ( error, path. to_owned ( ) ) ) ?;
123123
124124 Ok ( workspace)
125125 }
@@ -146,10 +146,10 @@ impl Load for PyProject<'_> {
146146 let path = path. as_ref ( ) ;
147147
148148 let string =
149- read_to_string ( path) . map_err ( |error| Error :: new_read ( error, path. to_owned ( ) ) ) ?;
149+ read_to_string ( path) . map_err ( |error| Self :: Error :: new_read ( error, path. to_owned ( ) ) ) ?;
150150
151- let workspace =
152- toml :: from_str ( & string ) . map_err ( |error| Error :: new_parse ( error, path. to_owned ( ) ) ) ?;
151+ let workspace = toml :: from_str ( & string )
152+ . map_err ( |error| Self :: Error :: new_parse ( error, path. to_owned ( ) ) ) ?;
153153
154154 Ok ( workspace)
155155 }
You can’t perform that action at this time.
0 commit comments