Function dummy_protocol_state

Source
pub fn dummy_protocol_state() -> MinaStateProtocolStateValueStableV2
Expand description

Core.Printf.eprintf !“PROTOCOL_STATE=%{sexp: Mina_state.Protocol_state.value}\n%!” state ;

let buf = Bigstring.create (Mina_state.Protocol_state.Value.Stable.V2.bin_size_t state) in ignore (Mina_state.Protocol_state.Value.Stable.V2.bin_write_t buf ~pos:0 state : int) ; let bytes = Bigstring.to_bytes buf in let explode s = List.init (String.length s) ~f:(fun i -> String.get s i) in let s = (String.concat ~sep:“,” (List.map (explode (Bytes.to_string bytes)) ~f:(fun b -> string_of_int (Char.to_int b)))) in

Core.Printf.eprintf !“state_binprot=[%s]\n%!” s;