Add trees to the env v2
The MR adds trees (aka "directories" aka "cursors" to the protocol.
!2488 (closed)(batched into) !2510 (merged) (Irmin 2.3 release)
- !2461 (merged) (refactor lib-storage signatures)
- !2440 (merged) (exposes trees in lib-storage)
- !2444 (merged) (env v2)
- !2466 (merged) (use irmin-mem to implement memory_context)
I've tried to split the commit into steps which compile and pass the unit-tests and so sometimes the changes have to cross the components. I hope it is ok but I am happy to do differently if needed.
The changes touches 3 components:
- the protocol environment
- the environment v2
- the alpha protocol
For each of these components I've tried to split the changes into 3 steps:
- extracting the context module type in an
_intf.mlto avoid code dupliction
- renaming the existing functions into more "functional" names (e.g.
getif the result is an option type)
- adding new tree functions and a new Tree module to manipulate the context Merkle tree and a more expressive
Side-effect: fixes #1043 (closed), as it makes
Proxy_context use the same backend as