Drup / ocaml-lmdb

Ocaml bindings for lmdb.
https://drup.github.io/ocaml-lmdb/dev/
MIT License
48 stars 3 forks source link

Remove Ro/Rw phantom type from Env and Map #23

Closed madroach closed 4 years ago

madroach commented 5 years ago

This change makes most (all?) subtype casts obsolete. The only downside is that attempts to write to a read-only environment will error at runtime rather than compiletime.

madroach commented 5 years ago

@Drup is this where you wanted to go with simplifying the phantom types? Simple enough?

Drup commented 5 years ago

@madroach Sorry, I'm really busy for at least a couple of weeks. I will have a look as soon as I can.

In any case, it looks like you only kept the permissions on transaction, which was my original design, so I would guess yes. :)

madroach commented 4 years ago

ping?

Drup commented 4 years ago

Let's go forward with this, as long as you fix CI. :)