Skip to content

Commit

Permalink
small addition to date range parser
Browse files Browse the repository at this point in the history
  • Loading branch information
howeyc committed Jan 14, 2022
1 parent 83a304a commit 80b89c2
Show file tree
Hide file tree
Showing 3 changed files with 614 additions and 537 deletions.
6 changes: 3 additions & 3 deletions ledger/cmd/internal/pdr/grammer.peg
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ Expr
<- NOW
/ PAST
/ FUTURE
/ ALLTIME
/ EVERYTHING

NOW
<- (CURRENT YEARS / YEARS TODATE / 'ytd' _)
Expand Down Expand Up @@ -116,8 +116,8 @@ FUTURE
}
}

ALLTIME
<- ('all time' _)
EVERYTHING
<- ('all time' / 'forever' / 'everything') _
{
p.start = time.Time{}
p.end = p.currentTime.Add(1<<63 -1)
Expand Down
Loading

0 comments on commit 80b89c2

Please sign in to comment.