diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/parse/scanner.rs | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/src/parse/scanner.rs b/src/parse/scanner.rs index c9c94769..9ee7641c 100644 --- a/src/parse/scanner.rs +++ b/src/parse/scanner.rs @@ -109,10 +109,7 @@ impl<'s> Scanner<'s> { /// The previous index in the source string. #[inline] pub fn last_index(&self) -> usize { - self.eaten() - .chars() - .next_back() - .map_or(0, |c| self.index - c.len_utf8()) + self.eaten().chars().last().map_or(0, |c| self.index - c.len_utf8()) } /// The current index in the source string. |
