rgrinberg/bencode — pull request #1 by c-cube (2014-01-17 19:13:41+00:00)
Title: non-blocking IO

Hi,

Since your library is already on opam, and I have some code for Bencode parsing and printing, I thought it would be interesting to merge our codebases. What I bring here is multifold:

- some `OUnit` and `QCheck` tests
- small functions (equality, hash)
- a `.mllib` file
- a module `Bencode_streaming` that contains necessary stuff for parsing and printing without blocking, which is typically useful for monadic IO (Lwt, Async, etc.). This code is complicated (parsing is hand-written with a state machine) but tested and I have never had problems so far.