From: Paul Eggert Date: Tue, 5 Aug 2003 05:14:20 +0000 (+0000) Subject: (date): Also accept dates like May-23-2003; suggestion X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=de6b4a96b25f5520d10607f67a8c14d55d23f884;p=pspp (date): Also accept dates like May-23-2003; suggestion from Karl Berry, implemented by Jim Meyering. --- diff --git a/lib/getdate.y b/lib/getdate.y index 3c4a04000f..b35130b7c8 100644 --- a/lib/getdate.y +++ b/lib/getdate.y @@ -321,6 +321,14 @@ date: PC.year.value = -$3.value; PC.year.digits = $3.digits; } + | tMONTH tSNUMBER tSNUMBER + { + /* e.g. JUN-17-1992. */ + PC.month = $1; + PC.day = -$2.value; + PC.year.value = -$3.value; + PC.year.digits = $3.digits; + } | tMONTH tUNUMBER { PC.month = $1;