aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_syntax/src/parser_impl/event.rs
diff options
context:
space:
mode:
Diffstat (limited to 'crates/ra_syntax/src/parser_impl/event.rs')
-rw-r--r--crates/ra_syntax/src/parser_impl/event.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/crates/ra_syntax/src/parser_impl/event.rs b/crates/ra_syntax/src/parser_impl/event.rs
index ced09bcff..1445401bc 100644
--- a/crates/ra_syntax/src/parser_impl/event.rs
+++ b/crates/ra_syntax/src/parser_impl/event.rs
@@ -15,6 +15,7 @@ use crate::{
15 TextRange, TextUnit, 15 TextRange, TextUnit,
16 yellow::syntax_error::{ 16 yellow::syntax_error::{
17 ParseError, 17 ParseError,
18 SyntaxError,
18 SyntaxErrorKind, 19 SyntaxErrorKind,
19 }, 20 },
20}; 21};
@@ -162,8 +163,7 @@ impl<'a, S: Sink> EventProcessor<'a, S> {
162 self.leaf(kind, len, n_raw_tokens); 163 self.leaf(kind, len, n_raw_tokens);
163 } 164 }
164 Event::Error { msg } => self.sink.error( 165 Event::Error { msg } => self.sink.error(
165 SyntaxErrorKind::ParseError(msg), 166 SyntaxError::new(SyntaxErrorKind::ParseError(msg), self.text_pos),
166 TextRange::offset_len(self.text_pos, 1.into()),
167 ), 167 ),
168 } 168 }
169 } 169 }