@@ -65,7 +65,8 @@ impl Emitter for SilentOnIgnoredFilesEmitter {
6565 }
6666 if let Some ( primary_span) = & db. span . primary_span ( ) {
6767 let file_name = self . source_map . span_to_filename ( * primary_span) ;
68- if let rustc_span:: FileName :: Real ( rustc_span:: RealFileName :: Named ( ref path) ) = file_name
68+ if let rustc_span:: FileName :: Real ( rustc_span:: RealFileName :: LocalPath ( ref path) ) =
69+ file_name
6970 {
7071 if self
7172 . ignore_path_set
@@ -157,7 +158,7 @@ impl ParseSess {
157158 self . parse_sess
158159 . source_map ( )
159160 . get_source_file ( & rustc_span:: FileName :: Real (
160- rustc_span:: RealFileName :: Named ( path. to_path_buf ( ) ) ,
161+ rustc_span:: RealFileName :: LocalPath ( path. to_path_buf ( ) ) ,
161162 ) )
162163 . is_some ( )
163164 }
@@ -347,7 +348,7 @@ mod tests {
347348 let source =
348349 String :: from ( r#"extern "system" fn jni_symbol!( funcName ) ( ... ) -> {} "# ) ;
349350 source_map. new_source_file (
350- SourceMapFileName :: Real ( RealFileName :: Named ( PathBuf :: from ( "foo.rs" ) ) ) ,
351+ SourceMapFileName :: Real ( RealFileName :: LocalPath ( PathBuf :: from ( "foo.rs" ) ) ) ,
351352 source,
352353 ) ;
353354 let mut emitter = build_emitter (
@@ -374,7 +375,7 @@ mod tests {
374375 let source_map = Lrc :: new ( SourceMap :: new ( FilePathMapping :: empty ( ) ) ) ;
375376 let source = String :: from ( r#"pub fn bar() { 1x; }"# ) ;
376377 source_map. new_source_file (
377- SourceMapFileName :: Real ( RealFileName :: Named ( PathBuf :: from ( "foo.rs" ) ) ) ,
378+ SourceMapFileName :: Real ( RealFileName :: LocalPath ( PathBuf :: from ( "foo.rs" ) ) ) ,
378379 source,
379380 ) ;
380381 let mut emitter = build_emitter (
@@ -400,7 +401,7 @@ mod tests {
400401 let source_map = Lrc :: new ( SourceMap :: new ( FilePathMapping :: empty ( ) ) ) ;
401402 let source = String :: from ( r#"pub fn bar() { 1x; }"# ) ;
402403 source_map. new_source_file (
403- SourceMapFileName :: Real ( RealFileName :: Named ( PathBuf :: from ( "foo.rs" ) ) ) ,
404+ SourceMapFileName :: Real ( RealFileName :: LocalPath ( PathBuf :: from ( "foo.rs" ) ) ) ,
404405 source,
405406 ) ;
406407 let mut emitter = build_emitter (
@@ -430,15 +431,15 @@ mod tests {
430431 let fatal_source =
431432 String :: from ( r#"extern "system" fn jni_symbol!( funcName ) ( ... ) -> {} "# ) ;
432433 source_map. new_source_file (
433- SourceMapFileName :: Real ( RealFileName :: Named ( PathBuf :: from ( "bar.rs" ) ) ) ,
434+ SourceMapFileName :: Real ( RealFileName :: LocalPath ( PathBuf :: from ( "bar.rs" ) ) ) ,
434435 bar_source,
435436 ) ;
436437 source_map. new_source_file (
437- SourceMapFileName :: Real ( RealFileName :: Named ( PathBuf :: from ( "foo.rs" ) ) ) ,
438+ SourceMapFileName :: Real ( RealFileName :: LocalPath ( PathBuf :: from ( "foo.rs" ) ) ) ,
438439 foo_source,
439440 ) ;
440441 source_map. new_source_file (
441- SourceMapFileName :: Real ( RealFileName :: Named ( PathBuf :: from ( "fatal.rs" ) ) ) ,
442+ SourceMapFileName :: Real ( RealFileName :: LocalPath ( PathBuf :: from ( "fatal.rs" ) ) ) ,
442443 fatal_source,
443444 ) ;
444445 let mut emitter = build_emitter (
0 commit comments