File tree Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -53,7 +53,7 @@ impl SourcemapParser {
5353 & self ,
5454 generated_line : u32 ,
5555 generated_column : u32 ,
56- ) -> PyResult < ( u32 , u32 , Option < String > , Option < String > ) > {
56+ ) -> PyResult < Option < ( u32 , u32 , Option < String > , Option < String > ) > > {
5757 if let Some ( Mapping { original, .. } ) =
5858 self
5959 . parsed_map
@@ -71,17 +71,17 @@ impl SourcemapParser {
7171 . sources
7272 . get ( location. source as usize )
7373 . map ( |str_slice| str_slice. to_string ( ) ) ;
74- return Ok ( (
74+ return Ok ( Some ( (
7575 location. original_line + 1 ,
7676 location. original_column + 1 ,
7777 source,
7878 name,
79- ) ) ;
79+ ) ) ) ;
8080 }
81- None => return Err ( PyErr :: new :: < exc :: TypeError , _ > ( "No original lines" ) ) ,
81+ None => return Ok ( None ) ,
8282 } ;
8383 }
84- Err ( PyErr :: new :: < exc :: TypeError , _ > ( "No sources found" ) )
84+ Ok ( None )
8585 }
8686}
8787
You can’t perform that action at this time.
0 commit comments