add lifetime to SyntaxError

This commit is contained in:
Folkert 2021-02-07 22:26:55 +01:00
parent 148fffe969
commit 38b21c3474
15 changed files with 208 additions and 158 deletions

View file

@ -8,7 +8,7 @@ use crate::parser::{
use bumpalo::collections::vec::Vec;
use bumpalo::Bump;
pub fn parse<'a>() -> impl Parser<'a, StrLiteral<'a>, SyntaxError> {
pub fn parse<'a>() -> impl Parser<'a, StrLiteral<'a>, SyntaxError<'a>> {
use StrLiteral::*;
move |arena: &'a Bump, mut state: State<'a>| {
@ -256,7 +256,7 @@ fn parse_block_string<'a, I>(
arena: &'a Bump,
state: State<'a>,
bytes: &mut I,
) -> ParseResult<'a, StrLiteral<'a>, SyntaxError>
) -> ParseResult<'a, StrLiteral<'a>, SyntaxError<'a>>
where
I: Iterator<Item = &'a u8>,
{