>> * replace our own patch parser with attoparsec
>
>> + import Data.Attoparsec.ByteString.Char8
>
> I was quite nervous about this until I compared the old code which
> also works on ByteString.Char8.
Yup. Our on-disk format is pretty much in terms of bytes, rather than
text/characters.
> I hope our test suite is good enough to rule out any edge case
> differences!
I did look at all the parsing primitives we export and compared them
with their attoparsec counterpart to make sure they are semantically
equivalent to what we had before. I am quite confident that there aren't
any edge-cases differences.
>> * take advantage of attoparsec error message for patches and
> inventories
>
> Great. I happened to notice some commented out parsers in
> Darcs.Repository.Inventory that we should probably just delete.
I had left them in there, back when I added this module, as some sort of
TODO comment. The low-level peeking and poking of the pristine hash we
do instead may be needed as an optimization, but is unsatisfying.
|