crclark / foundationdb-haskell

Haskell FFI bindings to the FoundationDB C API
https://crclark.github.io/foundationdb-haskell/
BSD 3-Clause "New" or "Revised" License
36 stars 5 forks source link

Fail to decode tuples when not all input consumed #31

Closed Dretch closed 4 years ago

Dretch commented 4 years ago

I am not sure if this is a bug, but I found it unexpected: currently, when decodeTupleElems does not consume all the input then it returns only the tuple elements it managed to read, instead of failing.

This pull request changes that behaviour so that it fails instead.

crclark commented 4 years ago

Oops! Good catch; thank you!