Parse descriptions properly

This commit is contained in:
Joscha 2021-11-18 23:57:10 +01:00
parent 90f74c82bc
commit 76eed7f30d
2 changed files with 7 additions and 13 deletions

View file

@ -72,10 +72,10 @@ except = !{ "EXCEPT" ~ datum ~ eol }
donedate = { "(" ~ datum ~ time ~ ")" }
done = !{ "DONE" ~ datum? ~ donedate? ~ eol }
// I need to use `nl` for the empty line here. Otherwise, the parser gets into
// an endless loop at the `EOI` since `indented*` can appear at the end of the
// file and would just repeatedly match the empty string.
indented_line = { NEWLINE | WHITESPACE ~ rest ~ eol }
// I need to use `NEWLINE` for the empty line here. Otherwise, the parser gets
// into an endless loop at the `EOI` since `indented*` can appear at the end of
// the file and would just repeatedly match the empty string.
indented_line = @{ NEWLINE | WHITESPACE ~ rest ~ eol }
description = { indented_line* }