From 20c5abba2f762e917503e3d613729f12607baf88 Mon Sep 17 00:00:00 2001 From: Marc Coquand Date: Fri, 12 Jan 2024 08:01:25 -0600 Subject: Implement support for dates --- lib/parser.mly | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'lib/parser.mly') diff --git a/lib/parser.mly b/lib/parser.mly index 177daaf..f14550e 100644 --- a/lib/parser.mly +++ b/lib/parser.mly @@ -11,6 +11,9 @@ %token COLON %token DOT %token EOF +%token PAST +%token FUTURE +%token NOW %token INTSYMBOL %token INT %token LBRACE @@ -56,6 +59,15 @@ row: | row_title = id_or_other; EMAIL; COMMA; r = row { Email (row_title, r) } | row_title = id_or_other; EMAIL { Email (row_title, End) } + | row_title = id_or_other; PAST; COMMA; r = row { Past (row_title, r) } + | row_title = id_or_other; PAST { Past (row_title, End) } + + | row_title = id_or_other; FUTURE; COMMA; r = row { Future (row_title, r) } + | row_title = id_or_other; FUTURE { Future (row_title, End) } + + | row_title = id_or_other; NOW; COMMA; r = row { Now (row_title, r) } + | row_title = id_or_other; NOW { Now (row_title, End) } + | row_title = id_or_other; USERNAME; COMMA; r = row { Username (row_title, r) } | row_title = id_or_other; USERNAME { Username (row_title, End) } -- cgit v1.2.3