Skip to content
This repository was archived by the owner on Jan 14, 2020. It is now read-only.
This repository was archived by the owner on Jan 14, 2020. It is now read-only.

User-defined witnesses in Json module are shadowed #16

@craigfe

Description

@craigfe

Because of the global open of Irmin.Type in the deriver, any user-defined witnesses in a Json module will be shadowed by the Irmin.Type.Json module.

module Json = struct
  include Yojson.Safe
  let t = Irmin.Type.(map string) from_string to_string
end

type bench_data = {
  uuid: Uuidm.t;
  data: Json.t
} [@@deriving irmin]

gives

32 | ..type bench_data = {
33 |     uuid: Uuidm.t;
34 |     data: Json.t
35 |   } [@@deriving irmin]
Error: Unbound value Json.t

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions