val vbool_reader: LL.leaf_reader vbool_parser
val vbool_reader: LL.leaf_reader vbool_parser
let vbool_reader =
 [@inline_let] let _ = lemma_synth_vbool_inj () in
 LL.read_synth' parse_vbool_key synth_vbool read_vbool_key ()
module Zeta.Formats.Aux.Vbool

(* This file has been automatically generated by EverParse. *)
open FStar.Bytes
module U8 = FStar.UInt8
module U16 = FStar.UInt16
module U32 = FStar.UInt32
module U64 = FStar.UInt64
module LP = LowParse.Spec
module LT = LowParse.TacLib
module LSZ = LowParse.SLow
module LPI = LowParse.Spec.AllIntegers
module LL = LowParse.Low
module L = FStar.List.Tot
module B = LowStar.Buffer
module BY = FStar.Bytes
module HS = FStar.HyperStack
module HST = FStar.HyperStack.ST

#reset-options "--using_facts_from '* -FStar.Tactics -FStar.Reflection' --z3rlimit 16 --z3cliopt smt.arith.nl=false --max_fuel 2 --max_ifuel 2"

[@LT.Norm] inline_for_extraction let vbool_enum : LP.enum vbool U8.t =
  [@inline_let] let e = [
    Vfalse, 0z;
    Vtrue, 1z;
  ] in
  [@inline_let] let _ =
    assert_norm (L.noRepeats (LP.list_map fst e))
  in
  [@inline_let] let _ = 
    assert_norm (L.noRepeats (LP.list_map snd e))
  in e

noextract let vbool_repr_parser = LPI.parse_u8

noextract let vbool_repr_serializer = LPI.serialize_u8

inline_for_extraction noextract let vbool_repr_size32 = LSZ.size32_u8

inline_for_extraction noextract let vbool_repr_validator = (LL.validate_u8 ())

inline_for_extraction noextract let vbool_repr_jumper = LL.jump_u8

inline_for_extraction noextract let vbool_repr_reader = LL.read_u8

inline_for_extraction noextract let vbool_repr_writer = LL.write_u8

inline_for_extraction let synth_vbool (x: LP.enum_key vbool_enum) : Tot vbool = x

inline_for_extraction let synth_vbool_inv (x: vbool) : Tot (LP.enum_key vbool_enum) =
  [@inline_let] let _ : squash (LP.list_mem x (LP.list_map fst vbool_enum)) =
    _ by (LP.synth_maybe_enum_key_inv_unknown_tac x)
  in
  x

let lemma_synth_vbool_inj () : Lemma
  (LP.synth_injective synth_vbool) = ()

let lemma_synth_vbool_inv () : Lemma
  (LP.synth_inverse synth_vbool synth_vbool_inv) = ()

noextract let parse_vbool_key : LP.parser _ (LP.enum_key vbool_enum) =
  LP.parse_enum_key vbool_repr_parser vbool_enum

noextract let serialize_vbool_key : LP.serializer parse_vbool_key =
  LP.serialize_enum_key vbool_repr_parser vbool_repr_serializer vbool_enum

noextract let vbool_parser : LP.parser _ vbool =
  lemma_synth_vbool_inj ();
  parse_vbool_key `LP.parse_synth` synth_vbool

noextract let vbool_serializer : LP.serializer vbool_parser =
  lemma_synth_vbool_inj ();
  lemma_synth_vbool_inv ();
  LP.serialize_synth _ synth_vbool serialize_vbool_key synth_vbool_inv ()

let vbool_bytesize (x:vbool) : GTot nat = Seq.length (vbool_serializer x)

let vbool_bytesize_eq x = ()

let vbool_size32 =
  [@inline_let] let _ = assert_norm (LSZ.size32_constant_precond vbool_serializer 1ul) in
  LSZ.size32_constant vbool_serializer 1ul ()

[@@ (LT.postprocess_with LT.pp_norm_tac)]
inline_for_extraction let validate_vbool_key : LL.validator parse_vbool_key =
    LL.mk_validate_enum_key vbool_repr_validator vbool_repr_reader vbool_enum

let vbool_validator =
  lemma_synth_vbool_inj ();
  LL.validate_synth validate_vbool_key synth_vbool ()

[@@ (LT.postprocess_with LT.pp_norm_tac) ]
inline_for_extraction let read_vbool_key : LL.leaf_reader parse_vbool_key =
  LL.mk_read_enum_key vbool_repr_reader vbool_enum
/
prims.fst.checked LowStar.Buffer.fst.checked LowParse.TacLib.fst.checked LowParse.Spec.AllIntegers.fst.checked LowParse.Spec.fst.checked LowParse.SLow.fst.checked LowParse.Low.fst.checked FStar.UInt8.fsti.checked FStar.UInt64.fsti.checked FStar.UInt32.fsti.checked FStar.UInt16.fsti.checked FStar.Tactics.Effect.fsti.checked FStar.Seq.fst.checked FStar.Pervasives.Native.fst.checked FStar.Pervasives.fsti.checked FStar.List.Tot.fst.checked FStar.HyperStack.ST.fsti.checked FStar.HyperStack.fst.checked FStar.Bytes.fsti.checked
Zeta.Formats.Aux.Vbool.fst
LowParse.Low.Base.leaf_reader Zeta.Formats.Aux.Vbool.vbool_parser
LowParse.Low.Combinators.read_synth' LowParse.Spec.Combinators.parse_filter_kind LowParse.Spec.Int.parse_u8_kind LowParse.Spec.Enum.enum_key Zeta.Formats.Aux.Vbool.vbool FStar.UInt8.t Zeta.Formats.Aux.Vbool.vbool_enum Zeta.Formats.Aux.Vbool.parse_vbool_key Zeta.Formats.Aux.Vbool.synth_vbool Zeta.Formats.Aux.Vbool.read_vbool_key Prims.unit Zeta.Formats.Aux.Vbool.lemma_synth_vbool_inj
let vbool_reader =
  
[@@ inline_let ]let _ = lemma_synth_vbool_inj () in
LL.read_synth' parse_vbool_key synth_vbool read_vbool_key ()