Module Tezos_raw_protocol_026_PtUSHuai.Misc

Helper functions

type 'a lazyt = unit -> 'a
val (-->) : int -> int -> int list

Include bounds

val (<--) : int -> int -> int list
val pp_print_paragraph : Tezos_protocol_environment_026_PtUSHuai.Format.formatter -> string -> unit
val take : int -> 'a list -> ('a list * 'a list) option
val remove_prefix : prefix:string -> string -> string option

Some (input with prefix removed), if string has prefix, else None

val remove_elem_from_list : int -> 'a list -> 'a list

remove nb list remove the first nb elements from the list list.

type Tezos_protocol_environment_026_PtUSHuai.Error_monad.error +=
  1. | Unreachable_error of {
    1. loc : string;
    2. message : string;
    }

Unreachable_error {loc; message} signals that the code at loc (a __LOC__) reached a path that it considers unreachable. Use it instead of assert false or failwith where a tzresult can be returned, so that a broken invariant makes the operation or block fail with an error rather than raise an exception.

unreachable_e ~loc fmt args fails with Unreachable_error {loc; message}, where message is formatted from fmt and args as by Format.asprintf.

Same as unreachable_e, in Lwt.