allow whitespace on empty lines

This commit is contained in:
xenofem 2020-06-19 02:17:11 -04:00
parent 35d0704740
commit e3998d1ff7

View file

@ -25,7 +25,7 @@ fn whitespace(input: &str) -> IResult<&str, ()> {
}
fn empty_line(input: &str) -> IResult<&str, ()> {
map(tuple((opt(comment), tag("\n"))), |_| ())(input)
map(tuple((whitespace, opt(comment), tag("\n"))), |_| ())(input)
}
pub fn take_until_any<T, Input, Error: ParseError<Input>>(tags: Vec<T>) -> impl Fn(Input) -> IResult<Input, Input, Error>