summaryrefslogtreecommitdiff
path: root/scantime.ll
diff options
context:
space:
mode:
Diffstat (limited to 'scantime.ll')
-rw-r--r--scantime.ll3
1 files changed, 3 insertions, 0 deletions
diff --git a/scantime.ll b/scantime.ll
index 02d00d78..75819bcc 100644
--- a/scantime.ll
+++ b/scantime.ll
@@ -13,6 +13,7 @@ extern YYSTYPE yylval;
shortmon (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)
longmon (January|February|March|April|May|June|July|August|September|October|November|December)
+ampm (AM|PM|am|pm|A.M.|P.M.|a.m.|p.m.|[AP]|[ap])
%%
@@ -26,4 +27,6 @@ longmon (January|February|March|April|May|June|July|August|September|October|No
{shortmon} yylval = ledger::intorchar(yytext); return TOK_MONTH;
{longmon} yylval = ledger::intorchar(yytext); return TOK_MONTH;
+{ampm} yylval = ledger::intorchar(yytext); return TOK_AMPM;
+
. return (int) yytext[0];