]> git.lizzy.rs Git - rust.git/blobdiff - src/librustc_errors/emitter.rs
mv FileMap SourceFile
[rust.git] / src / librustc_errors / emitter.rs
index 0a3e4d3ad25c0c555244f1cdaff06feefb052884..ce3a19677f2b9d9eb7c22e6f81c4536ccec8eb60 100644 (file)
@@ -10,7 +10,7 @@
 
 use self::Destination::*;
 
-use syntax_pos::{FileMap, Span, MultiSpan};
+use syntax_pos::{SourceFile, Span, MultiSpan};
 
 use {Level, CodeSuggestion, DiagnosticBuilder, SubDiagnostic, SourceMapperDyn, DiagnosticId};
 use snippet::{Annotation, AnnotationType, Line, MultilineAnnotation, StyledString, Style};
@@ -127,7 +127,7 @@ pub struct EmitterWriter {
 }
 
 struct FileWithAnnotatedLines {
-    file: Lrc<FileMap>,
+    file: Lrc<SourceFile>,
     lines: Vec<Line>,
     multiline_depth: usize,
 }
@@ -177,7 +177,7 @@ fn maybe_anonymized(&self, line_num: usize) -> String {
 
     fn preprocess_annotations(&mut self, msp: &MultiSpan) -> Vec<FileWithAnnotatedLines> {
         fn add_annotation_to_file(file_vec: &mut Vec<FileWithAnnotatedLines>,
-                                  file: Lrc<FileMap>,
+                                  file: Lrc<SourceFile>,
                                   line_index: usize,
                                   ann: Annotation) {
 
@@ -307,7 +307,7 @@ fn add_annotation_to_file(file_vec: &mut Vec<FileWithAnnotatedLines>,
 
     fn render_source_line(&self,
                           buffer: &mut StyledBuffer,
-                          file: Lrc<FileMap>,
+                          file: Lrc<SourceFile>,
                           line: &Line,
                           width_offset: usize,
                           code_offset: usize) -> Vec<(usize, Style)> {