about summary refs log tree commit diff
path: root/src/libsyntax/codemap.rs
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2017-12-02 20:06:42 +0000
committerbors <bors@rust-lang.org>2017-12-02 20:06:42 +0000
commitf9b0897c5d42a4dfa425db799073c6feb21b0178 (patch)
treeb92f2c4d8290b9998018f15f984e73e6bf8416c9 /src/libsyntax/codemap.rs
parent377decc352e58aa2bb0e2deb2eb66c3e7241a622 (diff)
parentfe897409579177d1ffd964b6d5a8de0024e5df68 (diff)
downloadrust-f9b0897c5d42a4dfa425db799073c6feb21b0178.tar.gz
rust-f9b0897c5d42a4dfa425db799073c6feb21b0178.zip
Auto merge of #46381 - estebank:expected-span, r=nikomatsakis
Point to next token when it is in the expected line

r? @nikomatsakis
Diffstat (limited to 'src/libsyntax/codemap.rs')
-rw-r--r--src/libsyntax/codemap.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/libsyntax/codemap.rs b/src/libsyntax/codemap.rs
index 3aac5334a38..3906ed431ce 100644
--- a/src/libsyntax/codemap.rs
+++ b/src/libsyntax/codemap.rs
@@ -358,7 +358,7 @@ impl CodeMap {
     }
 
     // If the relevant filemap is empty, we don't return a line number.
-    fn lookup_line(&self, pos: BytePos) -> Result<FileMapAndLine, Rc<FileMap>> {
+    pub fn lookup_line(&self, pos: BytePos) -> Result<FileMapAndLine, Rc<FileMap>> {
         let idx = self.lookup_filemap_idx(pos);
 
         let files = self.files.borrow();