Merkle_ledgermodule Any_ledger : sig ... endAny_ledger lets you use any arbitrary ledger whenever some ledger is * required. This uses dynamic dispatch and is equivalent to the notion of * consuming a value conforming to an interface in Java. * * It uses GADTs to type-erase the specific underlying first-class module * for some given signature and delegates all function calls. * * The restriction here is that one cannot conform to some signature that * exposes a `create` function because we can't magically pull a conforming * module out of thin air. However, one can always just pack any concrete * instance with the GADT constructor `witness`. * * Props to @nholland for showing me this trick. *
module Base_inputs_intf : sig ... endmodule Base_ledger_intf : sig ... endmodule Database : sig ... endmodule Database_intf : sig ... endmodule Graphviz : sig ... endmodule Intf : sig ... endmodule Ledger_extras_intf : sig ... endmodule Location : sig ... endmodule Location_intf : sig ... endmodule Merkle_ledger_intf : sig ... endmodule Merkle_path : sig ... endmodule Merkle_path_intf : sig ... endmodule Null_ledger : sig ... endmodule Syncable_intf : sig ... endmodule Util : sig ... end