Skip to content

[#432] Type-safe ByteString operations in Lorentz

Konstantin Ivanov requested to merge martoon/#432-typed-bytes into master

Description

In another project we are going to do some packing, hashing and signing, and currently Lorentz supports them not in a type-safe way.

In old projects unrelated to Tezos we used to create e.g. Hash algo a newtype that remembers the type of hashed data and used hashin algorithm, and adding such things here should improve type-safety, generated documentation and improve code readability.

I do changes in a breaking way, in hope that this is justified since we didn't care about work with bytes in Lorentz till now.

Autodoc sanity tested.

Moved to indigo repo in this MR.

Related issue(s)

Resolves #432 (closed)

Checklist for your Merge Request

Related changes (conditional)

  • Tests (see short guidelines)

    • If I added new functionality, I added tests covering it.
    • If I fixed a bug, I added a regression test to prevent the bug from silently reappearing again.
  • Documentation

    • I checked whether I should update the docs and did so if necessary:
    • I updated changelog files of all affected packages released to Hackage if my changes are externally visible.

Stylistic guide (mandatory)

Edited by Konstantin Ivanov

Merge request reports