[Haskell-cafe] date parsing and formatting

2010-11-15 Thread Alex Baranosky
I've been working with Haskell's Date.Time modules to parse a date like 12-4-1999 or 1-31-1999. I tried: parseDay :: String - Day parseDay s = readTime defaultTimeLocale %m%d%Y s And I think it wants my months and days to have exactly two digits instead of 1 or 2... What's the proper way to do

Re: [Haskell-cafe] date parsing and formatting

2010-11-15 Thread Anthony Cowley
On Sat, Nov 13, 2010 at 4:35 PM, Alex Baranosky alexander.barano...@gmail.com wrote: I've been working with Haskell's Date.Time modules to parse a date like 12-4-1999 or 1-31-1999. I tried: parseDay :: String - Day parseDay s = readTime defaultTimeLocale %m%d%Y s And I think it wants my