[Haskell-cafe] parsing currency amounts with parsec

Eric Rasmussen ericrasmussen at gmail.com
Thu May 12 07:59:18 CEST 2011


Very helpful -- thanks everyone! The handling of currency amounts in hledger
is what I was looking for in terms of alternate ways to parse and represent
dollar amounts in Haskell.

On Wed, May 11, 2011 at 6:05 PM, Simon Michael <simon at joyful.com> wrote:

> On 5/10/11 2:52 PM, Roman Cheplyaka wrote:
>
>> You could read hledger[1] sources for inspiration: it's written in
>> Haskell and contains some (quite generic) currency parsing.
>>
>
> Hi Eric.. here's the code in question:
>
>
> http://hackage.haskell.org/packages/archive/hledger-lib/0.14/doc/html/src/Hledger-Read-JournalReader.html#postingamount
>
> and some related docs:
>
> http://hledger.org/MANUAL.html#amounts
>
> It's probably more complicated and less efficient than you need, but a
> source of ideas.
>
>
>
> _______________________________________________
> Haskell-Cafe mailing list
> Haskell-Cafe at haskell.org
> http://www.haskell.org/mailman/listinfo/haskell-cafe
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.haskell.org/pipermail/haskell-cafe/attachments/20110511/13b1181e/attachment.htm>


More information about the Haskell-Cafe mailing list