aboutsummaryrefslogtreecommitdiff
path: root/compiler/src/lexer/mod.rs
diff options
context:
space:
mode:
Diffstat (limited to 'compiler/src/lexer/mod.rs')
-rw-r--r--compiler/src/lexer/mod.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/compiler/src/lexer/mod.rs b/compiler/src/lexer/mod.rs
index ff7d51d..464d88e 100644
--- a/compiler/src/lexer/mod.rs
+++ b/compiler/src/lexer/mod.rs
@@ -1,4 +1,4 @@
1use crate::span::{Pos, Span}; 1use crate::span::{Pos, Span, Spanned};
2 2
3#[cfg(test)] 3#[cfg(test)]
4mod tests; 4mod tests;
@@ -113,7 +113,7 @@ impl<'a> Lexer<'a> {
113} 113}
114 114
115impl<'a> Iterator for Lexer<'a> { 115impl<'a> Iterator for Lexer<'a> {
116 type Item = Span<Token<'a>>; 116 type Item = Spanned<Token<'a>>;
117 117
118 fn next(&mut self) -> Option<Self::Item> { 118 fn next(&mut self) -> Option<Self::Item> {
119 loop { 119 loop {
@@ -163,6 +163,6 @@ impl<'a> Iterator for Lexer<'a> {
163 }; 163 };
164 164
165 let end = Pos::new(self.line, self.column, self.cursor); 165 let end = Pos::new(self.line, self.column, self.cursor);
166 Some(Span::new(token, start, end)) 166 Some(Spanned::new(token, Span::new(start, end)))
167 } 167 }
168} 168}