Use relative positions inside a SourceFile.
This commit is contained in:
parent
9c25fbfa06
commit
96e583fd52
1 changed files with 1 additions and 1 deletions
|
|
@ -268,7 +268,7 @@ impl ParseSess {
|
|||
let source_file = self.parse_sess.source_map().lookup_char_pos(span.lo()).file;
|
||||
SnippetProvider::new(
|
||||
source_file.start_pos,
|
||||
source_file.end_pos,
|
||||
source_file.end_position(),
|
||||
Lrc::clone(source_file.src.as_ref().unwrap()),
|
||||
)
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue