alexey.skladnoy:
> В сообщении от 27 ноября 2009 23:09:53 Don Stewart написал:
> > alexey.skladnoy:
> > > Hello
> > >
> > >  Is there any plans to add error handling for binary? When it comes to
> > > binary parsing most awkward part is error handling
> > 
> > It is now available in the 'cereal' package. A strict binary with
> > explicit, checked error handling.
> > 
> It does but it was already noted that cereal uses strict bytestrings which 
> are 
> not really convenient when dealing with huge inputs. One may end up using 
> both 
> binary and cereal which is not really satisfactory.

It is quite hard to do a good job of lazy input, but explicit checked
errors (turning it into an Either Error a makes the whole stream
strict!).

You might want to look at designs that interleave error tokens in the
stream.

-- Don
_______________________________________________
Haskell-Cafe mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/haskell-cafe

Reply via email to