(* Generated by coq-of-rust *)
Require Import CoqOfRust.CoqOfRust.

Module extension.
  Module confidential_transfer.
    Module instruction.
      (*
      Enum ConfidentialTransferInstruction
      {
        ty_params := [];
        variants :=
          [
            {
              name := "InitializeMint";
              item := StructTuple [];
              discriminant := None;
            };
            {
              name := "UpdateMint";
              item := StructTuple [];
              discriminant := None;
            };
            {
              name := "ConfigureAccount";
              item := StructTuple [];
              discriminant := None;
            };
            {
              name := "ApproveAccount";
              item := StructTuple [];
              discriminant := None;
            };
            {
              name := "EmptyAccount";
              item := StructTuple [];
              discriminant := None;
            };
            {
              name := "Deposit";
              item := StructTuple [];
              discriminant := None;
            };
            {
              name := "Withdraw";
              item := StructTuple [];
              discriminant := None;
            };
            {
              name := "Transfer";
              item := StructTuple [];
              discriminant := None;
            };
            {
              name := "ApplyPendingBalance";
              item := StructTuple [];
              discriminant := None;
            };
            {
              name := "EnableConfidentialCredits";
              item := StructTuple [];
              discriminant := None;
            };
            {
              name := "DisableConfidentialCredits";
              item := StructTuple [];
              discriminant := None;
            };
            {
              name := "EnableNonConfidentialCredits";
              item := StructTuple [];
              discriminant := None;
            };
            {
              name := "DisableNonConfidentialCredits";
              item := StructTuple [];
              discriminant := None;
            };
            {
              name := "TransferWithSplitProofs";
              item := StructTuple [];
              discriminant := None;
            }
          ];
      }
      *)
      
      Module Impl_core_clone_Clone_for_spl_token_2022_extension_confidential_transfer_instruction_ConfidentialTransferInstruction.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction".
        
        (* Clone *)
        Definition clone (τ : list Ty.t) (α : list Value.t) : M :=
          match τ, α with
          | [], [ self ] =>
            ltac:(M.monadic
              (let self := M.alloc (| self |) in
              M.read (| M.read (| self |) |)))
          | _, _ => M.impossible
          end.
        
        Axiom Implements :
          M.IsTraitInstance
            "core::clone::Clone"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [ ("clone", InstanceField.Method clone) ].
      End Impl_core_clone_Clone_for_spl_token_2022_extension_confidential_transfer_instruction_ConfidentialTransferInstruction.
      
      Module Impl_core_marker_Copy_for_spl_token_2022_extension_confidential_transfer_instruction_ConfidentialTransferInstruction.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction".
        
        Axiom Implements :
          M.IsTraitInstance
            "core::marker::Copy"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [].
      End Impl_core_marker_Copy_for_spl_token_2022_extension_confidential_transfer_instruction_ConfidentialTransferInstruction.
      
      Module Impl_core_fmt_Debug_for_spl_token_2022_extension_confidential_transfer_instruction_ConfidentialTransferInstruction.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction".
        
        (* Debug *)
        Definition fmt (τ : list Ty.t) (α : list Value.t) : M :=
          match τ, α with
          | [], [ self; f ] =>
            ltac:(M.monadic
              (let self := M.alloc (| self |) in
              let f := M.alloc (| f |) in
              M.call_closure (|
                M.get_associated_function (| Ty.path "core::fmt::Formatter", "write_str", [] |),
                [
                  M.read (| f |);
                  M.read (|
                    M.match_operator (|
                      self,
                      [
                        fun γ =>
                          ltac:(M.monadic
                            (let γ := M.read (| γ |) in
                            M.alloc (| M.read (| Value.String "InitializeMint" |) |)));
                        fun γ =>
                          ltac:(M.monadic
                            (let γ := M.read (| γ |) in
                            M.alloc (| M.read (| Value.String "UpdateMint" |) |)));
                        fun γ =>
                          ltac:(M.monadic
                            (let γ := M.read (| γ |) in
                            M.alloc (| M.read (| Value.String "ConfigureAccount" |) |)));
                        fun γ =>
                          ltac:(M.monadic
                            (let γ := M.read (| γ |) in
                            M.alloc (| M.read (| Value.String "ApproveAccount" |) |)));
                        fun γ =>
                          ltac:(M.monadic
                            (let γ := M.read (| γ |) in
                            M.alloc (| M.read (| Value.String "EmptyAccount" |) |)));
                        fun γ =>
                          ltac:(M.monadic
                            (let γ := M.read (| γ |) in
                            M.alloc (| M.read (| Value.String "Deposit" |) |)));
                        fun γ =>
                          ltac:(M.monadic
                            (let γ := M.read (| γ |) in
                            M.alloc (| M.read (| Value.String "Withdraw" |) |)));
                        fun γ =>
                          ltac:(M.monadic
                            (let γ := M.read (| γ |) in
                            M.alloc (| M.read (| Value.String "Transfer" |) |)));
                        fun γ =>
                          ltac:(M.monadic
                            (let γ := M.read (| γ |) in
                            M.alloc (| M.read (| Value.String "ApplyPendingBalance" |) |)));
                        fun γ =>
                          ltac:(M.monadic
                            (let γ := M.read (| γ |) in
                            M.alloc (| M.read (| Value.String "EnableConfidentialCredits" |) |)));
                        fun γ =>
                          ltac:(M.monadic
                            (let γ := M.read (| γ |) in
                            M.alloc (| M.read (| Value.String "DisableConfidentialCredits" |) |)));
                        fun γ =>
                          ltac:(M.monadic
                            (let γ := M.read (| γ |) in
                            M.alloc (|
                              M.read (| Value.String "EnableNonConfidentialCredits" |)
                            |)));
                        fun γ =>
                          ltac:(M.monadic
                            (let γ := M.read (| γ |) in
                            M.alloc (|
                              M.read (| Value.String "DisableNonConfidentialCredits" |)
                            |)));
                        fun γ =>
                          ltac:(M.monadic
                            (let γ := M.read (| γ |) in
                            M.alloc (| M.read (| Value.String "TransferWithSplitProofs" |) |)))
                      ]
                    |)
                  |)
                ]
              |)))
          | _, _ => M.impossible
          end.
        
        Axiom Implements :
          M.IsTraitInstance
            "core::fmt::Debug"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [ ("fmt", InstanceField.Method fmt) ].
      End Impl_core_fmt_Debug_for_spl_token_2022_extension_confidential_transfer_instruction_ConfidentialTransferInstruction.
      
      Module Impl_num_enum_TryFromPrimitive_for_spl_token_2022_extension_confidential_transfer_instruction_ConfidentialTransferInstruction.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction".
        
        (* TryFromPrimitive *)
        Definition _Primitive : Ty.t := Ty.path "u8".
        
        (* TryFromPrimitive *)
        Definition _Error : Ty.t :=
          Ty.apply
            (Ty.path "num_enum::TryFromPrimitiveError")
            [
              Ty.path
                "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction"
            ].
        
        (* TryFromPrimitive *)
        (* Ty.apply (Ty.path "&") [ Ty.path "str" ] *)
        Definition value_NAME : Value.t :=
          M.run ltac:(M.monadic (Value.String "ConfidentialTransferInstruction")).
        
        (* TryFromPrimitive *)
        Definition try_from_primitive (τ : list Ty.t) (α : list Value.t) : M :=
          match τ, α with
          | [], [ number ] =>
            ltac:(M.monadic
              (let number := M.alloc (| number |) in
              M.read (|
                M.match_operator (|
                  number,
                  [
                    fun γ =>
                      ltac:(M.monadic
                        (let _ :=
                          M.is_constant_or_break_match (| M.read (| γ |), Value.Integer 0 |) in
                        M.alloc (|
                          Value.StructTuple
                            "core::result::Result::Ok"
                            [
                              Value.StructTuple
                                "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction::InitializeMint"
                                []
                            ]
                        |)));
                    fun γ =>
                      ltac:(M.monadic
                        (let _ :=
                          M.is_constant_or_break_match (| M.read (| γ |), Value.Integer 1 |) in
                        M.alloc (|
                          Value.StructTuple
                            "core::result::Result::Ok"
                            [
                              Value.StructTuple
                                "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction::UpdateMint"
                                []
                            ]
                        |)));
                    fun γ =>
                      ltac:(M.monadic
                        (let _ :=
                          M.is_constant_or_break_match (| M.read (| γ |), Value.Integer 2 |) in
                        M.alloc (|
                          Value.StructTuple
                            "core::result::Result::Ok"
                            [
                              Value.StructTuple
                                "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction::ConfigureAccount"
                                []
                            ]
                        |)));
                    fun γ =>
                      ltac:(M.monadic
                        (let _ :=
                          M.is_constant_or_break_match (| M.read (| γ |), Value.Integer 3 |) in
                        M.alloc (|
                          Value.StructTuple
                            "core::result::Result::Ok"
                            [
                              Value.StructTuple
                                "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction::ApproveAccount"
                                []
                            ]
                        |)));
                    fun γ =>
                      ltac:(M.monadic
                        (let _ :=
                          M.is_constant_or_break_match (| M.read (| γ |), Value.Integer 4 |) in
                        M.alloc (|
                          Value.StructTuple
                            "core::result::Result::Ok"
                            [
                              Value.StructTuple
                                "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction::EmptyAccount"
                                []
                            ]
                        |)));
                    fun γ =>
                      ltac:(M.monadic
                        (let _ :=
                          M.is_constant_or_break_match (| M.read (| γ |), Value.Integer 5 |) in
                        M.alloc (|
                          Value.StructTuple
                            "core::result::Result::Ok"
                            [
                              Value.StructTuple
                                "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction::Deposit"
                                []
                            ]
                        |)));
                    fun γ =>
                      ltac:(M.monadic
                        (let _ :=
                          M.is_constant_or_break_match (| M.read (| γ |), Value.Integer 6 |) in
                        M.alloc (|
                          Value.StructTuple
                            "core::result::Result::Ok"
                            [
                              Value.StructTuple
                                "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction::Withdraw"
                                []
                            ]
                        |)));
                    fun γ =>
                      ltac:(M.monadic
                        (let _ :=
                          M.is_constant_or_break_match (| M.read (| γ |), Value.Integer 7 |) in
                        M.alloc (|
                          Value.StructTuple
                            "core::result::Result::Ok"
                            [
                              Value.StructTuple
                                "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction::Transfer"
                                []
                            ]
                        |)));
                    fun γ =>
                      ltac:(M.monadic
                        (let _ :=
                          M.is_constant_or_break_match (| M.read (| γ |), Value.Integer 8 |) in
                        M.alloc (|
                          Value.StructTuple
                            "core::result::Result::Ok"
                            [
                              Value.StructTuple
                                "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction::ApplyPendingBalance"
                                []
                            ]
                        |)));
                    fun γ =>
                      ltac:(M.monadic
                        (let _ :=
                          M.is_constant_or_break_match (| M.read (| γ |), Value.Integer 9 |) in
                        M.alloc (|
                          Value.StructTuple
                            "core::result::Result::Ok"
                            [
                              Value.StructTuple
                                "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction::EnableConfidentialCredits"
                                []
                            ]
                        |)));
                    fun γ =>
                      ltac:(M.monadic
                        (let _ :=
                          M.is_constant_or_break_match (| M.read (| γ |), Value.Integer 10 |) in
                        M.alloc (|
                          Value.StructTuple
                            "core::result::Result::Ok"
                            [
                              Value.StructTuple
                                "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction::DisableConfidentialCredits"
                                []
                            ]
                        |)));
                    fun γ =>
                      ltac:(M.monadic
                        (let _ :=
                          M.is_constant_or_break_match (| M.read (| γ |), Value.Integer 11 |) in
                        M.alloc (|
                          Value.StructTuple
                            "core::result::Result::Ok"
                            [
                              Value.StructTuple
                                "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction::EnableNonConfidentialCredits"
                                []
                            ]
                        |)));
                    fun γ =>
                      ltac:(M.monadic
                        (let _ :=
                          M.is_constant_or_break_match (| M.read (| γ |), Value.Integer 12 |) in
                        M.alloc (|
                          Value.StructTuple
                            "core::result::Result::Ok"
                            [
                              Value.StructTuple
                                "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction::DisableNonConfidentialCredits"
                                []
                            ]
                        |)));
                    fun γ =>
                      ltac:(M.monadic
                        (let _ :=
                          M.is_constant_or_break_match (| M.read (| γ |), Value.Integer 13 |) in
                        M.alloc (|
                          Value.StructTuple
                            "core::result::Result::Ok"
                            [
                              Value.StructTuple
                                "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction::TransferWithSplitProofs"
                                []
                            ]
                        |)));
                    fun γ =>
                      ltac:(M.monadic
                        (M.alloc (|
                          Value.StructTuple
                            "core::result::Result::Err"
                            [
                              M.call_closure (|
                                M.get_associated_function (|
                                  Ty.apply
                                    (Ty.path "num_enum::TryFromPrimitiveError")
                                    [
                                      Ty.path
                                        "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction"
                                    ],
                                  "new",
                                  []
                                |),
                                [ M.read (| number |) ]
                              |)
                            ]
                        |)))
                  ]
                |)
              |)))
          | _, _ => M.impossible
          end.
        
        Axiom Implements :
          M.IsTraitInstance
            "num_enum::TryFromPrimitive"
            Self
            (* Trait polymorphic types *) []
            (* Instance *)
            [
              ("Primitive", InstanceField.Ty _Primitive);
              ("Error", InstanceField.Ty _Error);
              ("value_NAME", InstanceField.Constant value_NAME);
              ("try_from_primitive", InstanceField.Method try_from_primitive)
            ].
      End Impl_num_enum_TryFromPrimitive_for_spl_token_2022_extension_confidential_transfer_instruction_ConfidentialTransferInstruction.
      
      Module Impl_core_convert_TryFrom_u8_for_spl_token_2022_extension_confidential_transfer_instruction_ConfidentialTransferInstruction.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction".
        
        (* TryFromPrimitive *)
        Definition _Error : Ty.t :=
          Ty.apply
            (Ty.path "num_enum::TryFromPrimitiveError")
            [
              Ty.path
                "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction"
            ].
        
        (* TryFromPrimitive *)
        Definition try_from (τ : list Ty.t) (α : list Value.t) : M :=
          match τ, α with
          | [], [ number ] =>
            ltac:(M.monadic
              (let number := M.alloc (| number |) in
              M.call_closure (|
                M.get_trait_method (|
                  "num_enum::TryFromPrimitive",
                  Ty.path
                    "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction",
                  [],
                  "try_from_primitive",
                  []
                |),
                [ M.read (| number |) ]
              |)))
          | _, _ => M.impossible
          end.
        
        Axiom Implements :
          M.IsTraitInstance
            "core::convert::TryFrom"
            Self
            (* Trait polymorphic types *) [ (* T *) Ty.path "u8" ]
            (* Instance *)
            [ ("Error", InstanceField.Ty _Error); ("try_from", InstanceField.Method try_from) ].
      End Impl_core_convert_TryFrom_u8_for_spl_token_2022_extension_confidential_transfer_instruction_ConfidentialTransferInstruction.
      
      Module Impl_num_enum_CannotDeriveBothFromPrimitiveAndTryFromPrimitive_for_spl_token_2022_extension_confidential_transfer_instruction_ConfidentialTransferInstruction.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction".
        
        Axiom Implements :
          M.IsTraitInstance
            "num_enum::CannotDeriveBothFromPrimitiveAndTryFromPrimitive"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [].
      End Impl_num_enum_CannotDeriveBothFromPrimitiveAndTryFromPrimitive_for_spl_token_2022_extension_confidential_transfer_instruction_ConfidentialTransferInstruction.
      
      Module Impl_core_convert_From_spl_token_2022_extension_confidential_transfer_instruction_ConfidentialTransferInstruction_for_u8.
        Definition Self : Ty.t := Ty.path "u8".
        
        (* IntoPrimitive *)
        Definition from (τ : list Ty.t) (α : list Value.t) : M :=
          match τ, α with
          | [], [ enum_value ] =>
            ltac:(M.monadic
              (let enum_value := M.alloc (| enum_value |) in
              M.rust_cast (M.read (| enum_value |))))
          | _, _ => M.impossible
          end.
        
        Axiom Implements :
          M.IsTraitInstance
            "core::convert::From"
            Self
            (* Trait polymorphic types *)
            [
              (* T *)
              Ty.path
                "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction"
            ]
            (* Instance *) [ ("from", InstanceField.Method from) ].
      End Impl_core_convert_From_spl_token_2022_extension_confidential_transfer_instruction_ConfidentialTransferInstruction_for_u8.
      
      (* StructRecord
        {
          name := "InitializeMintData";
          ty_params := [];
          fields :=
            [
              ("authority", Ty.path "spl_pod::optional_keys::OptionalNonZeroPubkey");
              ("auto_approve_new_accounts", Ty.path "spl_pod::primitives::PodBool");
              ("auditor_elgamal_pubkey",
                Ty.path "spl_pod::optional_keys::OptionalNonZeroElGamalPubkey")
            ];
        } *)
      
      Module Impl_core_clone_Clone_for_spl_token_2022_extension_confidential_transfer_instruction_InitializeMintData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::InitializeMintData".
        
        (* Clone *)
        Definition clone (τ : list Ty.t) (α : list Value.t) : M :=
          match τ, α with
          | [], [ self ] =>
            ltac:(M.monadic
              (let self := M.alloc (| self |) in
              M.read (|
                M.match_operator (|
                  Value.DeclaredButUndefined,
                  [
                    fun γ =>
                      ltac:(M.monadic
                        (M.match_operator (|
                          Value.DeclaredButUndefined,
                          [
                            fun γ =>
                              ltac:(M.monadic
                                (M.match_operator (|
                                  Value.DeclaredButUndefined,
                                  [ fun γ => ltac:(M.monadic (M.read (| self |))) ]
                                |)))
                          ]
                        |)))
                  ]
                |)
              |)))
          | _, _ => M.impossible
          end.
        
        Axiom Implements :
          M.IsTraitInstance
            "core::clone::Clone"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [ ("clone", InstanceField.Method clone) ].
      End Impl_core_clone_Clone_for_spl_token_2022_extension_confidential_transfer_instruction_InitializeMintData.
      
      Module Impl_core_marker_Copy_for_spl_token_2022_extension_confidential_transfer_instruction_InitializeMintData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::InitializeMintData".
        
        Axiom Implements :
          M.IsTraitInstance
            "core::marker::Copy"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [].
      End Impl_core_marker_Copy_for_spl_token_2022_extension_confidential_transfer_instruction_InitializeMintData.
      
      Module Impl_core_fmt_Debug_for_spl_token_2022_extension_confidential_transfer_instruction_InitializeMintData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::InitializeMintData".
        
        (* Debug *)
        Definition fmt (τ : list Ty.t) (α : list Value.t) : M :=
          match τ, α with
          | [], [ self; f ] =>
            ltac:(M.monadic
              (let self := M.alloc (| self |) in
              let f := M.alloc (| f |) in
              M.call_closure (|
                M.get_associated_function (|
                  Ty.path "core::fmt::Formatter",
                  "debug_struct_field3_finish",
                  []
                |),
                [
                  M.read (| f |);
                  M.read (| Value.String "InitializeMintData" |);
                  M.read (| Value.String "authority" |);
                  (* Unsize *)
                  M.pointer_coercion
                    (M.SubPointer.get_struct_record_field (|
                      M.read (| self |),
                      "spl_token_2022::extension::confidential_transfer::instruction::InitializeMintData",
                      "authority"
                    |));
                  M.read (| Value.String "auto_approve_new_accounts" |);
                  (* Unsize *)
                  M.pointer_coercion
                    (M.SubPointer.get_struct_record_field (|
                      M.read (| self |),
                      "spl_token_2022::extension::confidential_transfer::instruction::InitializeMintData",
                      "auto_approve_new_accounts"
                    |));
                  M.read (| Value.String "auditor_elgamal_pubkey" |);
                  (* Unsize *)
                  M.pointer_coercion
                    (M.alloc (|
                      M.SubPointer.get_struct_record_field (|
                        M.read (| self |),
                        "spl_token_2022::extension::confidential_transfer::instruction::InitializeMintData",
                        "auditor_elgamal_pubkey"
                      |)
                    |))
                ]
              |)))
          | _, _ => M.impossible
          end.
        
        Axiom Implements :
          M.IsTraitInstance
            "core::fmt::Debug"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [ ("fmt", InstanceField.Method fmt) ].
      End Impl_core_fmt_Debug_for_spl_token_2022_extension_confidential_transfer_instruction_InitializeMintData.
      
      Module Impl_core_marker_StructuralPartialEq_for_spl_token_2022_extension_confidential_transfer_instruction_InitializeMintData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::InitializeMintData".
        
        Axiom Implements :
          M.IsTraitInstance
            "core::marker::StructuralPartialEq"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [].
      End Impl_core_marker_StructuralPartialEq_for_spl_token_2022_extension_confidential_transfer_instruction_InitializeMintData.
      
      Module Impl_core_cmp_PartialEq_for_spl_token_2022_extension_confidential_transfer_instruction_InitializeMintData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::InitializeMintData".
        
        (* PartialEq *)
        Definition eq (τ : list Ty.t) (α : list Value.t) : M :=
          match τ, α with
          | [], [ self; other ] =>
            ltac:(M.monadic
              (let self := M.alloc (| self |) in
              let other := M.alloc (| other |) in
              LogicalOp.and (|
                LogicalOp.and (|
                  M.call_closure (|
                    M.get_trait_method (|
                      "core::cmp::PartialEq",
                      Ty.path "spl_pod::optional_keys::OptionalNonZeroPubkey",
                      [ Ty.path "spl_pod::optional_keys::OptionalNonZeroPubkey" ],
                      "eq",
                      []
                    |),
                    [
                      M.SubPointer.get_struct_record_field (|
                        M.read (| self |),
                        "spl_token_2022::extension::confidential_transfer::instruction::InitializeMintData",
                        "authority"
                      |);
                      M.SubPointer.get_struct_record_field (|
                        M.read (| other |),
                        "spl_token_2022::extension::confidential_transfer::instruction::InitializeMintData",
                        "authority"
                      |)
                    ]
                  |),
                  ltac:(M.monadic
                    (M.call_closure (|
                      M.get_trait_method (|
                        "core::cmp::PartialEq",
                        Ty.path "spl_pod::primitives::PodBool",
                        [ Ty.path "spl_pod::primitives::PodBool" ],
                        "eq",
                        []
                      |),
                      [
                        M.SubPointer.get_struct_record_field (|
                          M.read (| self |),
                          "spl_token_2022::extension::confidential_transfer::instruction::InitializeMintData",
                          "auto_approve_new_accounts"
                        |);
                        M.SubPointer.get_struct_record_field (|
                          M.read (| other |),
                          "spl_token_2022::extension::confidential_transfer::instruction::InitializeMintData",
                          "auto_approve_new_accounts"
                        |)
                      ]
                    |)))
                |),
                ltac:(M.monadic
                  (M.call_closure (|
                    M.get_trait_method (|
                      "core::cmp::PartialEq",
                      Ty.path "spl_pod::optional_keys::OptionalNonZeroElGamalPubkey",
                      [ Ty.path "spl_pod::optional_keys::OptionalNonZeroElGamalPubkey" ],
                      "eq",
                      []
                    |),
                    [
                      M.SubPointer.get_struct_record_field (|
                        M.read (| self |),
                        "spl_token_2022::extension::confidential_transfer::instruction::InitializeMintData",
                        "auditor_elgamal_pubkey"
                      |);
                      M.SubPointer.get_struct_record_field (|
                        M.read (| other |),
                        "spl_token_2022::extension::confidential_transfer::instruction::InitializeMintData",
                        "auditor_elgamal_pubkey"
                      |)
                    ]
                  |)))
              |)))
          | _, _ => M.impossible
          end.
        
        Axiom Implements :
          M.IsTraitInstance
            "core::cmp::PartialEq"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [ ("eq", InstanceField.Method eq) ].
      End Impl_core_cmp_PartialEq_for_spl_token_2022_extension_confidential_transfer_instruction_InitializeMintData.
      
      Module Impl_bytemuck_pod_Pod_for_spl_token_2022_extension_confidential_transfer_instruction_InitializeMintData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::InitializeMintData".
        
        Axiom Implements :
          M.IsTraitInstance
            "bytemuck::pod::Pod"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [].
      End Impl_bytemuck_pod_Pod_for_spl_token_2022_extension_confidential_transfer_instruction_InitializeMintData.
      
      Module Impl_bytemuck_zeroable_Zeroable_for_spl_token_2022_extension_confidential_transfer_instruction_InitializeMintData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::InitializeMintData".
        
        Axiom Implements :
          M.IsTraitInstance
            "bytemuck::zeroable::Zeroable"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [].
      End Impl_bytemuck_zeroable_Zeroable_for_spl_token_2022_extension_confidential_transfer_instruction_InitializeMintData.
      
      (* StructRecord
        {
          name := "UpdateMintData";
          ty_params := [];
          fields :=
            [
              ("auto_approve_new_accounts", Ty.path "spl_pod::primitives::PodBool");
              ("auditor_elgamal_pubkey",
                Ty.path "spl_pod::optional_keys::OptionalNonZeroElGamalPubkey")
            ];
        } *)
      
      Module Impl_core_clone_Clone_for_spl_token_2022_extension_confidential_transfer_instruction_UpdateMintData.
        Definition Self : Ty.t :=
          Ty.path "spl_token_2022::extension::confidential_transfer::instruction::UpdateMintData".
        
        (* Clone *)
        Definition clone (τ : list Ty.t) (α : list Value.t) : M :=
          match τ, α with
          | [], [ self ] =>
            ltac:(M.monadic
              (let self := M.alloc (| self |) in
              M.read (|
                M.match_operator (|
                  Value.DeclaredButUndefined,
                  [
                    fun γ =>
                      ltac:(M.monadic
                        (M.match_operator (|
                          Value.DeclaredButUndefined,
                          [ fun γ => ltac:(M.monadic (M.read (| self |))) ]
                        |)))
                  ]
                |)
              |)))
          | _, _ => M.impossible
          end.
        
        Axiom Implements :
          M.IsTraitInstance
            "core::clone::Clone"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [ ("clone", InstanceField.Method clone) ].
      End Impl_core_clone_Clone_for_spl_token_2022_extension_confidential_transfer_instruction_UpdateMintData.
      
      Module Impl_core_marker_Copy_for_spl_token_2022_extension_confidential_transfer_instruction_UpdateMintData.
        Definition Self : Ty.t :=
          Ty.path "spl_token_2022::extension::confidential_transfer::instruction::UpdateMintData".
        
        Axiom Implements :
          M.IsTraitInstance
            "core::marker::Copy"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [].
      End Impl_core_marker_Copy_for_spl_token_2022_extension_confidential_transfer_instruction_UpdateMintData.
      
      Module Impl_core_fmt_Debug_for_spl_token_2022_extension_confidential_transfer_instruction_UpdateMintData.
        Definition Self : Ty.t :=
          Ty.path "spl_token_2022::extension::confidential_transfer::instruction::UpdateMintData".
        
        (* Debug *)
        Definition fmt (τ : list Ty.t) (α : list Value.t) : M :=
          match τ, α with
          | [], [ self; f ] =>
            ltac:(M.monadic
              (let self := M.alloc (| self |) in
              let f := M.alloc (| f |) in
              M.call_closure (|
                M.get_associated_function (|
                  Ty.path "core::fmt::Formatter",
                  "debug_struct_field2_finish",
                  []
                |),
                [
                  M.read (| f |);
                  M.read (| Value.String "UpdateMintData" |);
                  M.read (| Value.String "auto_approve_new_accounts" |);
                  (* Unsize *)
                  M.pointer_coercion
                    (M.SubPointer.get_struct_record_field (|
                      M.read (| self |),
                      "spl_token_2022::extension::confidential_transfer::instruction::UpdateMintData",
                      "auto_approve_new_accounts"
                    |));
                  M.read (| Value.String "auditor_elgamal_pubkey" |);
                  (* Unsize *)
                  M.pointer_coercion
                    (M.alloc (|
                      M.SubPointer.get_struct_record_field (|
                        M.read (| self |),
                        "spl_token_2022::extension::confidential_transfer::instruction::UpdateMintData",
                        "auditor_elgamal_pubkey"
                      |)
                    |))
                ]
              |)))
          | _, _ => M.impossible
          end.
        
        Axiom Implements :
          M.IsTraitInstance
            "core::fmt::Debug"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [ ("fmt", InstanceField.Method fmt) ].
      End Impl_core_fmt_Debug_for_spl_token_2022_extension_confidential_transfer_instruction_UpdateMintData.
      
      Module Impl_core_marker_StructuralPartialEq_for_spl_token_2022_extension_confidential_transfer_instruction_UpdateMintData.
        Definition Self : Ty.t :=
          Ty.path "spl_token_2022::extension::confidential_transfer::instruction::UpdateMintData".
        
        Axiom Implements :
          M.IsTraitInstance
            "core::marker::StructuralPartialEq"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [].
      End Impl_core_marker_StructuralPartialEq_for_spl_token_2022_extension_confidential_transfer_instruction_UpdateMintData.
      
      Module Impl_core_cmp_PartialEq_for_spl_token_2022_extension_confidential_transfer_instruction_UpdateMintData.
        Definition Self : Ty.t :=
          Ty.path "spl_token_2022::extension::confidential_transfer::instruction::UpdateMintData".
        
        (* PartialEq *)
        Definition eq (τ : list Ty.t) (α : list Value.t) : M :=
          match τ, α with
          | [], [ self; other ] =>
            ltac:(M.monadic
              (let self := M.alloc (| self |) in
              let other := M.alloc (| other |) in
              LogicalOp.and (|
                M.call_closure (|
                  M.get_trait_method (|
                    "core::cmp::PartialEq",
                    Ty.path "spl_pod::primitives::PodBool",
                    [ Ty.path "spl_pod::primitives::PodBool" ],
                    "eq",
                    []
                  |),
                  [
                    M.SubPointer.get_struct_record_field (|
                      M.read (| self |),
                      "spl_token_2022::extension::confidential_transfer::instruction::UpdateMintData",
                      "auto_approve_new_accounts"
                    |);
                    M.SubPointer.get_struct_record_field (|
                      M.read (| other |),
                      "spl_token_2022::extension::confidential_transfer::instruction::UpdateMintData",
                      "auto_approve_new_accounts"
                    |)
                  ]
                |),
                ltac:(M.monadic
                  (M.call_closure (|
                    M.get_trait_method (|
                      "core::cmp::PartialEq",
                      Ty.path "spl_pod::optional_keys::OptionalNonZeroElGamalPubkey",
                      [ Ty.path "spl_pod::optional_keys::OptionalNonZeroElGamalPubkey" ],
                      "eq",
                      []
                    |),
                    [
                      M.SubPointer.get_struct_record_field (|
                        M.read (| self |),
                        "spl_token_2022::extension::confidential_transfer::instruction::UpdateMintData",
                        "auditor_elgamal_pubkey"
                      |);
                      M.SubPointer.get_struct_record_field (|
                        M.read (| other |),
                        "spl_token_2022::extension::confidential_transfer::instruction::UpdateMintData",
                        "auditor_elgamal_pubkey"
                      |)
                    ]
                  |)))
              |)))
          | _, _ => M.impossible
          end.
        
        Axiom Implements :
          M.IsTraitInstance
            "core::cmp::PartialEq"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [ ("eq", InstanceField.Method eq) ].
      End Impl_core_cmp_PartialEq_for_spl_token_2022_extension_confidential_transfer_instruction_UpdateMintData.
      
      Module Impl_bytemuck_pod_Pod_for_spl_token_2022_extension_confidential_transfer_instruction_UpdateMintData.
        Definition Self : Ty.t :=
          Ty.path "spl_token_2022::extension::confidential_transfer::instruction::UpdateMintData".
        
        Axiom Implements :
          M.IsTraitInstance
            "bytemuck::pod::Pod"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [].
      End Impl_bytemuck_pod_Pod_for_spl_token_2022_extension_confidential_transfer_instruction_UpdateMintData.
      
      Module Impl_bytemuck_zeroable_Zeroable_for_spl_token_2022_extension_confidential_transfer_instruction_UpdateMintData.
        Definition Self : Ty.t :=
          Ty.path "spl_token_2022::extension::confidential_transfer::instruction::UpdateMintData".
        
        Axiom Implements :
          M.IsTraitInstance
            "bytemuck::zeroable::Zeroable"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [].
      End Impl_bytemuck_zeroable_Zeroable_for_spl_token_2022_extension_confidential_transfer_instruction_UpdateMintData.
      
      (* StructRecord
        {
          name := "ConfigureAccountInstructionData";
          ty_params := [];
          fields :=
            [
              ("decryptable_zero_balance",
                Ty.path
                  "solana_zk_token_sdk::zk_token_elgamal::pod::auth_encryption::AeCiphertext");
              ("maximum_pending_balance_credit_counter", Ty.path "spl_pod::primitives::PodU64");
              ("proof_instruction_offset", Ty.path "i8")
            ];
        } *)
      
      Module Impl_core_clone_Clone_for_spl_token_2022_extension_confidential_transfer_instruction_ConfigureAccountInstructionData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::ConfigureAccountInstructionData".
        
        (* Clone *)
        Definition clone (τ : list Ty.t) (α : list Value.t) : M :=
          match τ, α with
          | [], [ self ] =>
            ltac:(M.monadic
              (let self := M.alloc (| self |) in
              M.read (|
                M.match_operator (|
                  Value.DeclaredButUndefined,
                  [
                    fun γ =>
                      ltac:(M.monadic
                        (M.match_operator (|
                          Value.DeclaredButUndefined,
                          [
                            fun γ =>
                              ltac:(M.monadic
                                (M.match_operator (|
                                  Value.DeclaredButUndefined,
                                  [ fun γ => ltac:(M.monadic (M.read (| self |))) ]
                                |)))
                          ]
                        |)))
                  ]
                |)
              |)))
          | _, _ => M.impossible
          end.
        
        Axiom Implements :
          M.IsTraitInstance
            "core::clone::Clone"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [ ("clone", InstanceField.Method clone) ].
      End Impl_core_clone_Clone_for_spl_token_2022_extension_confidential_transfer_instruction_ConfigureAccountInstructionData.
      
      Module Impl_core_marker_Copy_for_spl_token_2022_extension_confidential_transfer_instruction_ConfigureAccountInstructionData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::ConfigureAccountInstructionData".
        
        Axiom Implements :
          M.IsTraitInstance
            "core::marker::Copy"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [].
      End Impl_core_marker_Copy_for_spl_token_2022_extension_confidential_transfer_instruction_ConfigureAccountInstructionData.
      
      Module Impl_core_fmt_Debug_for_spl_token_2022_extension_confidential_transfer_instruction_ConfigureAccountInstructionData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::ConfigureAccountInstructionData".
        
        (* Debug *)
        Definition fmt (τ : list Ty.t) (α : list Value.t) : M :=
          match τ, α with
          | [], [ self; f ] =>
            ltac:(M.monadic
              (let self := M.alloc (| self |) in
              let f := M.alloc (| f |) in
              M.call_closure (|
                M.get_associated_function (|
                  Ty.path "core::fmt::Formatter",
                  "debug_struct_field3_finish",
                  []
                |),
                [
                  M.read (| f |);
                  M.read (| Value.String "ConfigureAccountInstructionData" |);
                  M.read (| Value.String "decryptable_zero_balance" |);
                  (* Unsize *)
                  M.pointer_coercion
                    (M.SubPointer.get_struct_record_field (|
                      M.read (| self |),
                      "spl_token_2022::extension::confidential_transfer::instruction::ConfigureAccountInstructionData",
                      "decryptable_zero_balance"
                    |));
                  M.read (| Value.String "maximum_pending_balance_credit_counter" |);
                  (* Unsize *)
                  M.pointer_coercion
                    (M.SubPointer.get_struct_record_field (|
                      M.read (| self |),
                      "spl_token_2022::extension::confidential_transfer::instruction::ConfigureAccountInstructionData",
                      "maximum_pending_balance_credit_counter"
                    |));
                  M.read (| Value.String "proof_instruction_offset" |);
                  (* Unsize *)
                  M.pointer_coercion
                    (M.alloc (|
                      M.SubPointer.get_struct_record_field (|
                        M.read (| self |),
                        "spl_token_2022::extension::confidential_transfer::instruction::ConfigureAccountInstructionData",
                        "proof_instruction_offset"
                      |)
                    |))
                ]
              |)))
          | _, _ => M.impossible
          end.
        
        Axiom Implements :
          M.IsTraitInstance
            "core::fmt::Debug"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [ ("fmt", InstanceField.Method fmt) ].
      End Impl_core_fmt_Debug_for_spl_token_2022_extension_confidential_transfer_instruction_ConfigureAccountInstructionData.
      
      Module Impl_core_marker_StructuralPartialEq_for_spl_token_2022_extension_confidential_transfer_instruction_ConfigureAccountInstructionData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::ConfigureAccountInstructionData".
        
        Axiom Implements :
          M.IsTraitInstance
            "core::marker::StructuralPartialEq"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [].
      End Impl_core_marker_StructuralPartialEq_for_spl_token_2022_extension_confidential_transfer_instruction_ConfigureAccountInstructionData.
      
      Module Impl_core_cmp_PartialEq_for_spl_token_2022_extension_confidential_transfer_instruction_ConfigureAccountInstructionData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::ConfigureAccountInstructionData".
        
        (* PartialEq *)
        Definition eq (τ : list Ty.t) (α : list Value.t) : M :=
          match τ, α with
          | [], [ self; other ] =>
            ltac:(M.monadic
              (let self := M.alloc (| self |) in
              let other := M.alloc (| other |) in
              LogicalOp.and (|
                LogicalOp.and (|
                  M.call_closure (|
                    M.get_trait_method (|
                      "core::cmp::PartialEq",
                      Ty.path
                        "solana_zk_token_sdk::zk_token_elgamal::pod::auth_encryption::AeCiphertext",
                      [
                        Ty.path
                          "solana_zk_token_sdk::zk_token_elgamal::pod::auth_encryption::AeCiphertext"
                      ],
                      "eq",
                      []
                    |),
                    [
                      M.SubPointer.get_struct_record_field (|
                        M.read (| self |),
                        "spl_token_2022::extension::confidential_transfer::instruction::ConfigureAccountInstructionData",
                        "decryptable_zero_balance"
                      |);
                      M.SubPointer.get_struct_record_field (|
                        M.read (| other |),
                        "spl_token_2022::extension::confidential_transfer::instruction::ConfigureAccountInstructionData",
                        "decryptable_zero_balance"
                      |)
                    ]
                  |),
                  ltac:(M.monadic
                    (M.call_closure (|
                      M.get_trait_method (|
                        "core::cmp::PartialEq",
                        Ty.path "spl_pod::primitives::PodU64",
                        [ Ty.path "spl_pod::primitives::PodU64" ],
                        "eq",
                        []
                      |),
                      [
                        M.SubPointer.get_struct_record_field (|
                          M.read (| self |),
                          "spl_token_2022::extension::confidential_transfer::instruction::ConfigureAccountInstructionData",
                          "maximum_pending_balance_credit_counter"
                        |);
                        M.SubPointer.get_struct_record_field (|
                          M.read (| other |),
                          "spl_token_2022::extension::confidential_transfer::instruction::ConfigureAccountInstructionData",
                          "maximum_pending_balance_credit_counter"
                        |)
                      ]
                    |)))
                |),
                ltac:(M.monadic
                  (BinOp.Pure.eq
                    (M.read (|
                      M.SubPointer.get_struct_record_field (|
                        M.read (| self |),
                        "spl_token_2022::extension::confidential_transfer::instruction::ConfigureAccountInstructionData",
                        "proof_instruction_offset"
                      |)
                    |))
                    (M.read (|
                      M.SubPointer.get_struct_record_field (|
                        M.read (| other |),
                        "spl_token_2022::extension::confidential_transfer::instruction::ConfigureAccountInstructionData",
                        "proof_instruction_offset"
                      |)
                    |))))
              |)))
          | _, _ => M.impossible
          end.
        
        Axiom Implements :
          M.IsTraitInstance
            "core::cmp::PartialEq"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [ ("eq", InstanceField.Method eq) ].
      End Impl_core_cmp_PartialEq_for_spl_token_2022_extension_confidential_transfer_instruction_ConfigureAccountInstructionData.
      
      Module Impl_bytemuck_pod_Pod_for_spl_token_2022_extension_confidential_transfer_instruction_ConfigureAccountInstructionData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::ConfigureAccountInstructionData".
        
        Axiom Implements :
          M.IsTraitInstance
            "bytemuck::pod::Pod"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [].
      End Impl_bytemuck_pod_Pod_for_spl_token_2022_extension_confidential_transfer_instruction_ConfigureAccountInstructionData.
      
      Module Impl_bytemuck_zeroable_Zeroable_for_spl_token_2022_extension_confidential_transfer_instruction_ConfigureAccountInstructionData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::ConfigureAccountInstructionData".
        
        Axiom Implements :
          M.IsTraitInstance
            "bytemuck::zeroable::Zeroable"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [].
      End Impl_bytemuck_zeroable_Zeroable_for_spl_token_2022_extension_confidential_transfer_instruction_ConfigureAccountInstructionData.
      
      (* StructRecord
        {
          name := "EmptyAccountInstructionData";
          ty_params := [];
          fields := [ ("proof_instruction_offset", Ty.path "i8") ];
        } *)
      
      Module Impl_core_clone_Clone_for_spl_token_2022_extension_confidential_transfer_instruction_EmptyAccountInstructionData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::EmptyAccountInstructionData".
        
        (* Clone *)
        Definition clone (τ : list Ty.t) (α : list Value.t) : M :=
          match τ, α with
          | [], [ self ] =>
            ltac:(M.monadic
              (let self := M.alloc (| self |) in
              M.read (|
                M.match_operator (|
                  Value.DeclaredButUndefined,
                  [ fun γ => ltac:(M.monadic (M.read (| self |))) ]
                |)
              |)))
          | _, _ => M.impossible
          end.
        
        Axiom Implements :
          M.IsTraitInstance
            "core::clone::Clone"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [ ("clone", InstanceField.Method clone) ].
      End Impl_core_clone_Clone_for_spl_token_2022_extension_confidential_transfer_instruction_EmptyAccountInstructionData.
      
      Module Impl_core_marker_Copy_for_spl_token_2022_extension_confidential_transfer_instruction_EmptyAccountInstructionData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::EmptyAccountInstructionData".
        
        Axiom Implements :
          M.IsTraitInstance
            "core::marker::Copy"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [].
      End Impl_core_marker_Copy_for_spl_token_2022_extension_confidential_transfer_instruction_EmptyAccountInstructionData.
      
      Module Impl_core_fmt_Debug_for_spl_token_2022_extension_confidential_transfer_instruction_EmptyAccountInstructionData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::EmptyAccountInstructionData".
        
        (* Debug *)
        Definition fmt (τ : list Ty.t) (α : list Value.t) : M :=
          match τ, α with
          | [], [ self; f ] =>
            ltac:(M.monadic
              (let self := M.alloc (| self |) in
              let f := M.alloc (| f |) in
              M.call_closure (|
                M.get_associated_function (|
                  Ty.path "core::fmt::Formatter",
                  "debug_struct_field1_finish",
                  []
                |),
                [
                  M.read (| f |);
                  M.read (| Value.String "EmptyAccountInstructionData" |);
                  M.read (| Value.String "proof_instruction_offset" |);
                  (* Unsize *)
                  M.pointer_coercion
                    (M.alloc (|
                      M.SubPointer.get_struct_record_field (|
                        M.read (| self |),
                        "spl_token_2022::extension::confidential_transfer::instruction::EmptyAccountInstructionData",
                        "proof_instruction_offset"
                      |)
                    |))
                ]
              |)))
          | _, _ => M.impossible
          end.
        
        Axiom Implements :
          M.IsTraitInstance
            "core::fmt::Debug"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [ ("fmt", InstanceField.Method fmt) ].
      End Impl_core_fmt_Debug_for_spl_token_2022_extension_confidential_transfer_instruction_EmptyAccountInstructionData.
      
      Module Impl_core_marker_StructuralPartialEq_for_spl_token_2022_extension_confidential_transfer_instruction_EmptyAccountInstructionData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::EmptyAccountInstructionData".
        
        Axiom Implements :
          M.IsTraitInstance
            "core::marker::StructuralPartialEq"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [].
      End Impl_core_marker_StructuralPartialEq_for_spl_token_2022_extension_confidential_transfer_instruction_EmptyAccountInstructionData.
      
      Module Impl_core_cmp_PartialEq_for_spl_token_2022_extension_confidential_transfer_instruction_EmptyAccountInstructionData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::EmptyAccountInstructionData".
        
        (* PartialEq *)
        Definition eq (τ : list Ty.t) (α : list Value.t) : M :=
          match τ, α with
          | [], [ self; other ] =>
            ltac:(M.monadic
              (let self := M.alloc (| self |) in
              let other := M.alloc (| other |) in
              BinOp.Pure.eq
                (M.read (|
                  M.SubPointer.get_struct_record_field (|
                    M.read (| self |),
                    "spl_token_2022::extension::confidential_transfer::instruction::EmptyAccountInstructionData",
                    "proof_instruction_offset"
                  |)
                |))
                (M.read (|
                  M.SubPointer.get_struct_record_field (|
                    M.read (| other |),
                    "spl_token_2022::extension::confidential_transfer::instruction::EmptyAccountInstructionData",
                    "proof_instruction_offset"
                  |)
                |))))
          | _, _ => M.impossible
          end.
        
        Axiom Implements :
          M.IsTraitInstance
            "core::cmp::PartialEq"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [ ("eq", InstanceField.Method eq) ].
      End Impl_core_cmp_PartialEq_for_spl_token_2022_extension_confidential_transfer_instruction_EmptyAccountInstructionData.
      
      Module Impl_bytemuck_pod_Pod_for_spl_token_2022_extension_confidential_transfer_instruction_EmptyAccountInstructionData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::EmptyAccountInstructionData".
        
        Axiom Implements :
          M.IsTraitInstance
            "bytemuck::pod::Pod"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [].
      End Impl_bytemuck_pod_Pod_for_spl_token_2022_extension_confidential_transfer_instruction_EmptyAccountInstructionData.
      
      Module Impl_bytemuck_zeroable_Zeroable_for_spl_token_2022_extension_confidential_transfer_instruction_EmptyAccountInstructionData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::EmptyAccountInstructionData".
        
        Axiom Implements :
          M.IsTraitInstance
            "bytemuck::zeroable::Zeroable"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [].
      End Impl_bytemuck_zeroable_Zeroable_for_spl_token_2022_extension_confidential_transfer_instruction_EmptyAccountInstructionData.
      
      (* StructRecord
        {
          name := "DepositInstructionData";
          ty_params := [];
          fields :=
            [ ("amount", Ty.path "spl_pod::primitives::PodU64"); ("decimals", Ty.path "u8") ];
        } *)
      
      Module Impl_core_clone_Clone_for_spl_token_2022_extension_confidential_transfer_instruction_DepositInstructionData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::DepositInstructionData".
        
        (* Clone *)
        Definition clone (τ : list Ty.t) (α : list Value.t) : M :=
          match τ, α with
          | [], [ self ] =>
            ltac:(M.monadic
              (let self := M.alloc (| self |) in
              M.read (|
                M.match_operator (|
                  Value.DeclaredButUndefined,
                  [
                    fun γ =>
                      ltac:(M.monadic
                        (M.match_operator (|
                          Value.DeclaredButUndefined,
                          [ fun γ => ltac:(M.monadic (M.read (| self |))) ]
                        |)))
                  ]
                |)
              |)))
          | _, _ => M.impossible
          end.
        
        Axiom Implements :
          M.IsTraitInstance
            "core::clone::Clone"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [ ("clone", InstanceField.Method clone) ].
      End Impl_core_clone_Clone_for_spl_token_2022_extension_confidential_transfer_instruction_DepositInstructionData.
      
      Module Impl_core_marker_Copy_for_spl_token_2022_extension_confidential_transfer_instruction_DepositInstructionData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::DepositInstructionData".
        
        Axiom Implements :
          M.IsTraitInstance
            "core::marker::Copy"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [].
      End Impl_core_marker_Copy_for_spl_token_2022_extension_confidential_transfer_instruction_DepositInstructionData.
      
      Module Impl_core_fmt_Debug_for_spl_token_2022_extension_confidential_transfer_instruction_DepositInstructionData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::DepositInstructionData".
        
        (* Debug *)
        Definition fmt (τ : list Ty.t) (α : list Value.t) : M :=
          match τ, α with
          | [], [ self; f ] =>
            ltac:(M.monadic
              (let self := M.alloc (| self |) in
              let f := M.alloc (| f |) in
              M.call_closure (|
                M.get_associated_function (|
                  Ty.path "core::fmt::Formatter",
                  "debug_struct_field2_finish",
                  []
                |),
                [
                  M.read (| f |);
                  M.read (| Value.String "DepositInstructionData" |);
                  M.read (| Value.String "amount" |);
                  (* Unsize *)
                  M.pointer_coercion
                    (M.SubPointer.get_struct_record_field (|
                      M.read (| self |),
                      "spl_token_2022::extension::confidential_transfer::instruction::DepositInstructionData",
                      "amount"
                    |));
                  M.read (| Value.String "decimals" |);
                  (* Unsize *)
                  M.pointer_coercion
                    (M.alloc (|
                      M.SubPointer.get_struct_record_field (|
                        M.read (| self |),
                        "spl_token_2022::extension::confidential_transfer::instruction::DepositInstructionData",
                        "decimals"
                      |)
                    |))
                ]
              |)))
          | _, _ => M.impossible
          end.
        
        Axiom Implements :
          M.IsTraitInstance
            "core::fmt::Debug"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [ ("fmt", InstanceField.Method fmt) ].
      End Impl_core_fmt_Debug_for_spl_token_2022_extension_confidential_transfer_instruction_DepositInstructionData.
      
      Module Impl_core_marker_StructuralPartialEq_for_spl_token_2022_extension_confidential_transfer_instruction_DepositInstructionData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::DepositInstructionData".
        
        Axiom Implements :
          M.IsTraitInstance
            "core::marker::StructuralPartialEq"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [].
      End Impl_core_marker_StructuralPartialEq_for_spl_token_2022_extension_confidential_transfer_instruction_DepositInstructionData.
      
      Module Impl_core_cmp_PartialEq_for_spl_token_2022_extension_confidential_transfer_instruction_DepositInstructionData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::DepositInstructionData".
        
        (* PartialEq *)
        Definition eq (τ : list Ty.t) (α : list Value.t) : M :=
          match τ, α with
          | [], [ self; other ] =>
            ltac:(M.monadic
              (let self := M.alloc (| self |) in
              let other := M.alloc (| other |) in
              LogicalOp.and (|
                M.call_closure (|
                  M.get_trait_method (|
                    "core::cmp::PartialEq",
                    Ty.path "spl_pod::primitives::PodU64",
                    [ Ty.path "spl_pod::primitives::PodU64" ],
                    "eq",
                    []
                  |),
                  [
                    M.SubPointer.get_struct_record_field (|
                      M.read (| self |),
                      "spl_token_2022::extension::confidential_transfer::instruction::DepositInstructionData",
                      "amount"
                    |);
                    M.SubPointer.get_struct_record_field (|
                      M.read (| other |),
                      "spl_token_2022::extension::confidential_transfer::instruction::DepositInstructionData",
                      "amount"
                    |)
                  ]
                |),
                ltac:(M.monadic
                  (BinOp.Pure.eq
                    (M.read (|
                      M.SubPointer.get_struct_record_field (|
                        M.read (| self |),
                        "spl_token_2022::extension::confidential_transfer::instruction::DepositInstructionData",
                        "decimals"
                      |)
                    |))
                    (M.read (|
                      M.SubPointer.get_struct_record_field (|
                        M.read (| other |),
                        "spl_token_2022::extension::confidential_transfer::instruction::DepositInstructionData",
                        "decimals"
                      |)
                    |))))
              |)))
          | _, _ => M.impossible
          end.
        
        Axiom Implements :
          M.IsTraitInstance
            "core::cmp::PartialEq"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [ ("eq", InstanceField.Method eq) ].
      End Impl_core_cmp_PartialEq_for_spl_token_2022_extension_confidential_transfer_instruction_DepositInstructionData.
      
      Module Impl_bytemuck_pod_Pod_for_spl_token_2022_extension_confidential_transfer_instruction_DepositInstructionData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::DepositInstructionData".
        
        Axiom Implements :
          M.IsTraitInstance
            "bytemuck::pod::Pod"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [].
      End Impl_bytemuck_pod_Pod_for_spl_token_2022_extension_confidential_transfer_instruction_DepositInstructionData.
      
      Module Impl_bytemuck_zeroable_Zeroable_for_spl_token_2022_extension_confidential_transfer_instruction_DepositInstructionData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::DepositInstructionData".
        
        Axiom Implements :
          M.IsTraitInstance
            "bytemuck::zeroable::Zeroable"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [].
      End Impl_bytemuck_zeroable_Zeroable_for_spl_token_2022_extension_confidential_transfer_instruction_DepositInstructionData.
      
      (* StructRecord
        {
          name := "WithdrawInstructionData";
          ty_params := [];
          fields :=
            [
              ("amount", Ty.path "spl_pod::primitives::PodU64");
              ("decimals", Ty.path "u8");
              ("new_decryptable_available_balance",
                Ty.path
                  "solana_zk_token_sdk::zk_token_elgamal::pod::auth_encryption::AeCiphertext");
              ("proof_instruction_offset", Ty.path "i8")
            ];
        } *)
      
      Module Impl_core_clone_Clone_for_spl_token_2022_extension_confidential_transfer_instruction_WithdrawInstructionData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::WithdrawInstructionData".
        
        (* Clone *)
        Definition clone (τ : list Ty.t) (α : list Value.t) : M :=
          match τ, α with
          | [], [ self ] =>
            ltac:(M.monadic
              (let self := M.alloc (| self |) in
              M.read (|
                M.match_operator (|
                  Value.DeclaredButUndefined,
                  [
                    fun γ =>
                      ltac:(M.monadic
                        (M.match_operator (|
                          Value.DeclaredButUndefined,
                          [
                            fun γ =>
                              ltac:(M.monadic
                                (M.match_operator (|
                                  Value.DeclaredButUndefined,
                                  [
                                    fun γ =>
                                      ltac:(M.monadic
                                        (M.match_operator (|
                                          Value.DeclaredButUndefined,
                                          [ fun γ => ltac:(M.monadic (M.read (| self |))) ]
                                        |)))
                                  ]
                                |)))
                          ]
                        |)))
                  ]
                |)
              |)))
          | _, _ => M.impossible
          end.
        
        Axiom Implements :
          M.IsTraitInstance
            "core::clone::Clone"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [ ("clone", InstanceField.Method clone) ].
      End Impl_core_clone_Clone_for_spl_token_2022_extension_confidential_transfer_instruction_WithdrawInstructionData.
      
      Module Impl_core_marker_Copy_for_spl_token_2022_extension_confidential_transfer_instruction_WithdrawInstructionData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::WithdrawInstructionData".
        
        Axiom Implements :
          M.IsTraitInstance
            "core::marker::Copy"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [].
      End Impl_core_marker_Copy_for_spl_token_2022_extension_confidential_transfer_instruction_WithdrawInstructionData.
      
      Module Impl_core_fmt_Debug_for_spl_token_2022_extension_confidential_transfer_instruction_WithdrawInstructionData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::WithdrawInstructionData".
        
        (* Debug *)
        Definition fmt (τ : list Ty.t) (α : list Value.t) : M :=
          match τ, α with
          | [], [ self; f ] =>
            ltac:(M.monadic
              (let self := M.alloc (| self |) in
              let f := M.alloc (| f |) in
              M.call_closure (|
                M.get_associated_function (|
                  Ty.path "core::fmt::Formatter",
                  "debug_struct_field4_finish",
                  []
                |),
                [
                  M.read (| f |);
                  M.read (| Value.String "WithdrawInstructionData" |);
                  M.read (| Value.String "amount" |);
                  (* Unsize *)
                  M.pointer_coercion
                    (M.SubPointer.get_struct_record_field (|
                      M.read (| self |),
                      "spl_token_2022::extension::confidential_transfer::instruction::WithdrawInstructionData",
                      "amount"
                    |));
                  M.read (| Value.String "decimals" |);
                  (* Unsize *)
                  M.pointer_coercion
                    (M.SubPointer.get_struct_record_field (|
                      M.read (| self |),
                      "spl_token_2022::extension::confidential_transfer::instruction::WithdrawInstructionData",
                      "decimals"
                    |));
                  M.read (| Value.String "new_decryptable_available_balance" |);
                  (* Unsize *)
                  M.pointer_coercion
                    (M.SubPointer.get_struct_record_field (|
                      M.read (| self |),
                      "spl_token_2022::extension::confidential_transfer::instruction::WithdrawInstructionData",
                      "new_decryptable_available_balance"
                    |));
                  M.read (| Value.String "proof_instruction_offset" |);
                  (* Unsize *)
                  M.pointer_coercion
                    (M.alloc (|
                      M.SubPointer.get_struct_record_field (|
                        M.read (| self |),
                        "spl_token_2022::extension::confidential_transfer::instruction::WithdrawInstructionData",
                        "proof_instruction_offset"
                      |)
                    |))
                ]
              |)))
          | _, _ => M.impossible
          end.
        
        Axiom Implements :
          M.IsTraitInstance
            "core::fmt::Debug"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [ ("fmt", InstanceField.Method fmt) ].
      End Impl_core_fmt_Debug_for_spl_token_2022_extension_confidential_transfer_instruction_WithdrawInstructionData.
      
      Module Impl_core_marker_StructuralPartialEq_for_spl_token_2022_extension_confidential_transfer_instruction_WithdrawInstructionData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::WithdrawInstructionData".
        
        Axiom Implements :
          M.IsTraitInstance
            "core::marker::StructuralPartialEq"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [].
      End Impl_core_marker_StructuralPartialEq_for_spl_token_2022_extension_confidential_transfer_instruction_WithdrawInstructionData.
      
      Module Impl_core_cmp_PartialEq_for_spl_token_2022_extension_confidential_transfer_instruction_WithdrawInstructionData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::WithdrawInstructionData".
        
        (* PartialEq *)
        Definition eq (τ : list Ty.t) (α : list Value.t) : M :=
          match τ, α with
          | [], [ self; other ] =>
            ltac:(M.monadic
              (let self := M.alloc (| self |) in
              let other := M.alloc (| other |) in
              LogicalOp.and (|
                LogicalOp.and (|
                  LogicalOp.and (|
                    M.call_closure (|
                      M.get_trait_method (|
                        "core::cmp::PartialEq",
                        Ty.path "spl_pod::primitives::PodU64",
                        [ Ty.path "spl_pod::primitives::PodU64" ],
                        "eq",
                        []
                      |),
                      [
                        M.SubPointer.get_struct_record_field (|
                          M.read (| self |),
                          "spl_token_2022::extension::confidential_transfer::instruction::WithdrawInstructionData",
                          "amount"
                        |);
                        M.SubPointer.get_struct_record_field (|
                          M.read (| other |),
                          "spl_token_2022::extension::confidential_transfer::instruction::WithdrawInstructionData",
                          "amount"
                        |)
                      ]
                    |),
                    ltac:(M.monadic
                      (BinOp.Pure.eq
                        (M.read (|
                          M.SubPointer.get_struct_record_field (|
                            M.read (| self |),
                            "spl_token_2022::extension::confidential_transfer::instruction::WithdrawInstructionData",
                            "decimals"
                          |)
                        |))
                        (M.read (|
                          M.SubPointer.get_struct_record_field (|
                            M.read (| other |),
                            "spl_token_2022::extension::confidential_transfer::instruction::WithdrawInstructionData",
                            "decimals"
                          |)
                        |))))
                  |),
                  ltac:(M.monadic
                    (M.call_closure (|
                      M.get_trait_method (|
                        "core::cmp::PartialEq",
                        Ty.path
                          "solana_zk_token_sdk::zk_token_elgamal::pod::auth_encryption::AeCiphertext",
                        [
                          Ty.path
                            "solana_zk_token_sdk::zk_token_elgamal::pod::auth_encryption::AeCiphertext"
                        ],
                        "eq",
                        []
                      |),
                      [
                        M.SubPointer.get_struct_record_field (|
                          M.read (| self |),
                          "spl_token_2022::extension::confidential_transfer::instruction::WithdrawInstructionData",
                          "new_decryptable_available_balance"
                        |);
                        M.SubPointer.get_struct_record_field (|
                          M.read (| other |),
                          "spl_token_2022::extension::confidential_transfer::instruction::WithdrawInstructionData",
                          "new_decryptable_available_balance"
                        |)
                      ]
                    |)))
                |),
                ltac:(M.monadic
                  (BinOp.Pure.eq
                    (M.read (|
                      M.SubPointer.get_struct_record_field (|
                        M.read (| self |),
                        "spl_token_2022::extension::confidential_transfer::instruction::WithdrawInstructionData",
                        "proof_instruction_offset"
                      |)
                    |))
                    (M.read (|
                      M.SubPointer.get_struct_record_field (|
                        M.read (| other |),
                        "spl_token_2022::extension::confidential_transfer::instruction::WithdrawInstructionData",
                        "proof_instruction_offset"
                      |)
                    |))))
              |)))
          | _, _ => M.impossible
          end.
        
        Axiom Implements :
          M.IsTraitInstance
            "core::cmp::PartialEq"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [ ("eq", InstanceField.Method eq) ].
      End Impl_core_cmp_PartialEq_for_spl_token_2022_extension_confidential_transfer_instruction_WithdrawInstructionData.
      
      Module Impl_bytemuck_pod_Pod_for_spl_token_2022_extension_confidential_transfer_instruction_WithdrawInstructionData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::WithdrawInstructionData".
        
        Axiom Implements :
          M.IsTraitInstance
            "bytemuck::pod::Pod"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [].
      End Impl_bytemuck_pod_Pod_for_spl_token_2022_extension_confidential_transfer_instruction_WithdrawInstructionData.
      
      Module Impl_bytemuck_zeroable_Zeroable_for_spl_token_2022_extension_confidential_transfer_instruction_WithdrawInstructionData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::WithdrawInstructionData".
        
        Axiom Implements :
          M.IsTraitInstance
            "bytemuck::zeroable::Zeroable"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [].
      End Impl_bytemuck_zeroable_Zeroable_for_spl_token_2022_extension_confidential_transfer_instruction_WithdrawInstructionData.
      
      (* StructRecord
        {
          name := "TransferInstructionData";
          ty_params := [];
          fields :=
            [
              ("new_source_decryptable_available_balance",
                Ty.path
                  "solana_zk_token_sdk::zk_token_elgamal::pod::auth_encryption::AeCiphertext");
              ("proof_instruction_offset", Ty.path "i8")
            ];
        } *)
      
      Module Impl_core_clone_Clone_for_spl_token_2022_extension_confidential_transfer_instruction_TransferInstructionData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::TransferInstructionData".
        
        (* Clone *)
        Definition clone (τ : list Ty.t) (α : list Value.t) : M :=
          match τ, α with
          | [], [ self ] =>
            ltac:(M.monadic
              (let self := M.alloc (| self |) in
              M.read (|
                M.match_operator (|
                  Value.DeclaredButUndefined,
                  [
                    fun γ =>
                      ltac:(M.monadic
                        (M.match_operator (|
                          Value.DeclaredButUndefined,
                          [ fun γ => ltac:(M.monadic (M.read (| self |))) ]
                        |)))
                  ]
                |)
              |)))
          | _, _ => M.impossible
          end.
        
        Axiom Implements :
          M.IsTraitInstance
            "core::clone::Clone"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [ ("clone", InstanceField.Method clone) ].
      End Impl_core_clone_Clone_for_spl_token_2022_extension_confidential_transfer_instruction_TransferInstructionData.
      
      Module Impl_core_marker_Copy_for_spl_token_2022_extension_confidential_transfer_instruction_TransferInstructionData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::TransferInstructionData".
        
        Axiom Implements :
          M.IsTraitInstance
            "core::marker::Copy"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [].
      End Impl_core_marker_Copy_for_spl_token_2022_extension_confidential_transfer_instruction_TransferInstructionData.
      
      Module Impl_core_fmt_Debug_for_spl_token_2022_extension_confidential_transfer_instruction_TransferInstructionData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::TransferInstructionData".
        
        (* Debug *)
        Definition fmt (τ : list Ty.t) (α : list Value.t) : M :=
          match τ, α with
          | [], [ self; f ] =>
            ltac:(M.monadic
              (let self := M.alloc (| self |) in
              let f := M.alloc (| f |) in
              M.call_closure (|
                M.get_associated_function (|
                  Ty.path "core::fmt::Formatter",
                  "debug_struct_field2_finish",
                  []
                |),
                [
                  M.read (| f |);
                  M.read (| Value.String "TransferInstructionData" |);
                  M.read (| Value.String "new_source_decryptable_available_balance" |);
                  (* Unsize *)
                  M.pointer_coercion
                    (M.SubPointer.get_struct_record_field (|
                      M.read (| self |),
                      "spl_token_2022::extension::confidential_transfer::instruction::TransferInstructionData",
                      "new_source_decryptable_available_balance"
                    |));
                  M.read (| Value.String "proof_instruction_offset" |);
                  (* Unsize *)
                  M.pointer_coercion
                    (M.alloc (|
                      M.SubPointer.get_struct_record_field (|
                        M.read (| self |),
                        "spl_token_2022::extension::confidential_transfer::instruction::TransferInstructionData",
                        "proof_instruction_offset"
                      |)
                    |))
                ]
              |)))
          | _, _ => M.impossible
          end.
        
        Axiom Implements :
          M.IsTraitInstance
            "core::fmt::Debug"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [ ("fmt", InstanceField.Method fmt) ].
      End Impl_core_fmt_Debug_for_spl_token_2022_extension_confidential_transfer_instruction_TransferInstructionData.
      
      Module Impl_core_marker_StructuralPartialEq_for_spl_token_2022_extension_confidential_transfer_instruction_TransferInstructionData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::TransferInstructionData".
        
        Axiom Implements :
          M.IsTraitInstance
            "core::marker::StructuralPartialEq"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [].
      End Impl_core_marker_StructuralPartialEq_for_spl_token_2022_extension_confidential_transfer_instruction_TransferInstructionData.
      
      Module Impl_core_cmp_PartialEq_for_spl_token_2022_extension_confidential_transfer_instruction_TransferInstructionData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::TransferInstructionData".
        
        (* PartialEq *)
        Definition eq (τ : list Ty.t) (α : list Value.t) : M :=
          match τ, α with
          | [], [ self; other ] =>
            ltac:(M.monadic
              (let self := M.alloc (| self |) in
              let other := M.alloc (| other |) in
              LogicalOp.and (|
                M.call_closure (|
                  M.get_trait_method (|
                    "core::cmp::PartialEq",
                    Ty.path
                      "solana_zk_token_sdk::zk_token_elgamal::pod::auth_encryption::AeCiphertext",
                    [
                      Ty.path
                        "solana_zk_token_sdk::zk_token_elgamal::pod::auth_encryption::AeCiphertext"
                    ],
                    "eq",
                    []
                  |),
                  [
                    M.SubPointer.get_struct_record_field (|
                      M.read (| self |),
                      "spl_token_2022::extension::confidential_transfer::instruction::TransferInstructionData",
                      "new_source_decryptable_available_balance"
                    |);
                    M.SubPointer.get_struct_record_field (|
                      M.read (| other |),
                      "spl_token_2022::extension::confidential_transfer::instruction::TransferInstructionData",
                      "new_source_decryptable_available_balance"
                    |)
                  ]
                |),
                ltac:(M.monadic
                  (BinOp.Pure.eq
                    (M.read (|
                      M.SubPointer.get_struct_record_field (|
                        M.read (| self |),
                        "spl_token_2022::extension::confidential_transfer::instruction::TransferInstructionData",
                        "proof_instruction_offset"
                      |)
                    |))
                    (M.read (|
                      M.SubPointer.get_struct_record_field (|
                        M.read (| other |),
                        "spl_token_2022::extension::confidential_transfer::instruction::TransferInstructionData",
                        "proof_instruction_offset"
                      |)
                    |))))
              |)))
          | _, _ => M.impossible
          end.
        
        Axiom Implements :
          M.IsTraitInstance
            "core::cmp::PartialEq"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [ ("eq", InstanceField.Method eq) ].
      End Impl_core_cmp_PartialEq_for_spl_token_2022_extension_confidential_transfer_instruction_TransferInstructionData.
      
      Module Impl_bytemuck_pod_Pod_for_spl_token_2022_extension_confidential_transfer_instruction_TransferInstructionData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::TransferInstructionData".
        
        Axiom Implements :
          M.IsTraitInstance
            "bytemuck::pod::Pod"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [].
      End Impl_bytemuck_pod_Pod_for_spl_token_2022_extension_confidential_transfer_instruction_TransferInstructionData.
      
      Module Impl_bytemuck_zeroable_Zeroable_for_spl_token_2022_extension_confidential_transfer_instruction_TransferInstructionData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::TransferInstructionData".
        
        Axiom Implements :
          M.IsTraitInstance
            "bytemuck::zeroable::Zeroable"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [].
      End Impl_bytemuck_zeroable_Zeroable_for_spl_token_2022_extension_confidential_transfer_instruction_TransferInstructionData.
      
      (* StructRecord
        {
          name := "ApplyPendingBalanceData";
          ty_params := [];
          fields :=
            [
              ("expected_pending_balance_credit_counter", Ty.path "spl_pod::primitives::PodU64");
              ("new_decryptable_available_balance",
                Ty.path "solana_zk_token_sdk::zk_token_elgamal::pod::auth_encryption::AeCiphertext")
            ];
        } *)
      
      Module Impl_core_clone_Clone_for_spl_token_2022_extension_confidential_transfer_instruction_ApplyPendingBalanceData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::ApplyPendingBalanceData".
        
        (* Clone *)
        Definition clone (τ : list Ty.t) (α : list Value.t) : M :=
          match τ, α with
          | [], [ self ] =>
            ltac:(M.monadic
              (let self := M.alloc (| self |) in
              M.read (|
                M.match_operator (|
                  Value.DeclaredButUndefined,
                  [
                    fun γ =>
                      ltac:(M.monadic
                        (M.match_operator (|
                          Value.DeclaredButUndefined,
                          [ fun γ => ltac:(M.monadic (M.read (| self |))) ]
                        |)))
                  ]
                |)
              |)))
          | _, _ => M.impossible
          end.
        
        Axiom Implements :
          M.IsTraitInstance
            "core::clone::Clone"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [ ("clone", InstanceField.Method clone) ].
      End Impl_core_clone_Clone_for_spl_token_2022_extension_confidential_transfer_instruction_ApplyPendingBalanceData.
      
      Module Impl_core_marker_Copy_for_spl_token_2022_extension_confidential_transfer_instruction_ApplyPendingBalanceData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::ApplyPendingBalanceData".
        
        Axiom Implements :
          M.IsTraitInstance
            "core::marker::Copy"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [].
      End Impl_core_marker_Copy_for_spl_token_2022_extension_confidential_transfer_instruction_ApplyPendingBalanceData.
      
      Module Impl_core_fmt_Debug_for_spl_token_2022_extension_confidential_transfer_instruction_ApplyPendingBalanceData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::ApplyPendingBalanceData".
        
        (* Debug *)
        Definition fmt (τ : list Ty.t) (α : list Value.t) : M :=
          match τ, α with
          | [], [ self; f ] =>
            ltac:(M.monadic
              (let self := M.alloc (| self |) in
              let f := M.alloc (| f |) in
              M.call_closure (|
                M.get_associated_function (|
                  Ty.path "core::fmt::Formatter",
                  "debug_struct_field2_finish",
                  []
                |),
                [
                  M.read (| f |);
                  M.read (| Value.String "ApplyPendingBalanceData" |);
                  M.read (| Value.String "expected_pending_balance_credit_counter" |);
                  (* Unsize *)
                  M.pointer_coercion
                    (M.SubPointer.get_struct_record_field (|
                      M.read (| self |),
                      "spl_token_2022::extension::confidential_transfer::instruction::ApplyPendingBalanceData",
                      "expected_pending_balance_credit_counter"
                    |));
                  M.read (| Value.String "new_decryptable_available_balance" |);
                  (* Unsize *)
                  M.pointer_coercion
                    (M.alloc (|
                      M.SubPointer.get_struct_record_field (|
                        M.read (| self |),
                        "spl_token_2022::extension::confidential_transfer::instruction::ApplyPendingBalanceData",
                        "new_decryptable_available_balance"
                      |)
                    |))
                ]
              |)))
          | _, _ => M.impossible
          end.
        
        Axiom Implements :
          M.IsTraitInstance
            "core::fmt::Debug"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [ ("fmt", InstanceField.Method fmt) ].
      End Impl_core_fmt_Debug_for_spl_token_2022_extension_confidential_transfer_instruction_ApplyPendingBalanceData.
      
      Module Impl_core_marker_StructuralPartialEq_for_spl_token_2022_extension_confidential_transfer_instruction_ApplyPendingBalanceData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::ApplyPendingBalanceData".
        
        Axiom Implements :
          M.IsTraitInstance
            "core::marker::StructuralPartialEq"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [].
      End Impl_core_marker_StructuralPartialEq_for_spl_token_2022_extension_confidential_transfer_instruction_ApplyPendingBalanceData.
      
      Module Impl_core_cmp_PartialEq_for_spl_token_2022_extension_confidential_transfer_instruction_ApplyPendingBalanceData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::ApplyPendingBalanceData".
        
        (* PartialEq *)
        Definition eq (τ : list Ty.t) (α : list Value.t) : M :=
          match τ, α with
          | [], [ self; other ] =>
            ltac:(M.monadic
              (let self := M.alloc (| self |) in
              let other := M.alloc (| other |) in
              LogicalOp.and (|
                M.call_closure (|
                  M.get_trait_method (|
                    "core::cmp::PartialEq",
                    Ty.path "spl_pod::primitives::PodU64",
                    [ Ty.path "spl_pod::primitives::PodU64" ],
                    "eq",
                    []
                  |),
                  [
                    M.SubPointer.get_struct_record_field (|
                      M.read (| self |),
                      "spl_token_2022::extension::confidential_transfer::instruction::ApplyPendingBalanceData",
                      "expected_pending_balance_credit_counter"
                    |);
                    M.SubPointer.get_struct_record_field (|
                      M.read (| other |),
                      "spl_token_2022::extension::confidential_transfer::instruction::ApplyPendingBalanceData",
                      "expected_pending_balance_credit_counter"
                    |)
                  ]
                |),
                ltac:(M.monadic
                  (M.call_closure (|
                    M.get_trait_method (|
                      "core::cmp::PartialEq",
                      Ty.path
                        "solana_zk_token_sdk::zk_token_elgamal::pod::auth_encryption::AeCiphertext",
                      [
                        Ty.path
                          "solana_zk_token_sdk::zk_token_elgamal::pod::auth_encryption::AeCiphertext"
                      ],
                      "eq",
                      []
                    |),
                    [
                      M.SubPointer.get_struct_record_field (|
                        M.read (| self |),
                        "spl_token_2022::extension::confidential_transfer::instruction::ApplyPendingBalanceData",
                        "new_decryptable_available_balance"
                      |);
                      M.SubPointer.get_struct_record_field (|
                        M.read (| other |),
                        "spl_token_2022::extension::confidential_transfer::instruction::ApplyPendingBalanceData",
                        "new_decryptable_available_balance"
                      |)
                    ]
                  |)))
              |)))
          | _, _ => M.impossible
          end.
        
        Axiom Implements :
          M.IsTraitInstance
            "core::cmp::PartialEq"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [ ("eq", InstanceField.Method eq) ].
      End Impl_core_cmp_PartialEq_for_spl_token_2022_extension_confidential_transfer_instruction_ApplyPendingBalanceData.
      
      Module Impl_bytemuck_pod_Pod_for_spl_token_2022_extension_confidential_transfer_instruction_ApplyPendingBalanceData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::ApplyPendingBalanceData".
        
        Axiom Implements :
          M.IsTraitInstance
            "bytemuck::pod::Pod"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [].
      End Impl_bytemuck_pod_Pod_for_spl_token_2022_extension_confidential_transfer_instruction_ApplyPendingBalanceData.
      
      Module Impl_bytemuck_zeroable_Zeroable_for_spl_token_2022_extension_confidential_transfer_instruction_ApplyPendingBalanceData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::ApplyPendingBalanceData".
        
        Axiom Implements :
          M.IsTraitInstance
            "bytemuck::zeroable::Zeroable"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [].
      End Impl_bytemuck_zeroable_Zeroable_for_spl_token_2022_extension_confidential_transfer_instruction_ApplyPendingBalanceData.
      
      (* StructRecord
        {
          name := "TransferWithSplitProofsInstructionData";
          ty_params := [];
          fields :=
            [
              ("new_source_decryptable_available_balance",
                Ty.path
                  "solana_zk_token_sdk::zk_token_elgamal::pod::auth_encryption::AeCiphertext");
              ("no_op_on_uninitialized_split_context_state",
                Ty.path "spl_pod::primitives::PodBool");
              ("close_split_context_state_on_execution", Ty.path "spl_pod::primitives::PodBool");
              ("source_decrypt_handles",
                Ty.path
                  "spl_token_2022::extension::confidential_transfer::ciphertext_extraction::SourceDecryptHandles")
            ];
        } *)
      
      Module Impl_core_clone_Clone_for_spl_token_2022_extension_confidential_transfer_instruction_TransferWithSplitProofsInstructionData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::TransferWithSplitProofsInstructionData".
        
        (* Clone *)
        Definition clone (τ : list Ty.t) (α : list Value.t) : M :=
          match τ, α with
          | [], [ self ] =>
            ltac:(M.monadic
              (let self := M.alloc (| self |) in
              M.read (|
                M.match_operator (|
                  Value.DeclaredButUndefined,
                  [
                    fun γ =>
                      ltac:(M.monadic
                        (M.match_operator (|
                          Value.DeclaredButUndefined,
                          [
                            fun γ =>
                              ltac:(M.monadic
                                (M.match_operator (|
                                  Value.DeclaredButUndefined,
                                  [ fun γ => ltac:(M.monadic (M.read (| self |))) ]
                                |)))
                          ]
                        |)))
                  ]
                |)
              |)))
          | _, _ => M.impossible
          end.
        
        Axiom Implements :
          M.IsTraitInstance
            "core::clone::Clone"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [ ("clone", InstanceField.Method clone) ].
      End Impl_core_clone_Clone_for_spl_token_2022_extension_confidential_transfer_instruction_TransferWithSplitProofsInstructionData.
      
      Module Impl_core_marker_Copy_for_spl_token_2022_extension_confidential_transfer_instruction_TransferWithSplitProofsInstructionData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::TransferWithSplitProofsInstructionData".
        
        Axiom Implements :
          M.IsTraitInstance
            "core::marker::Copy"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [].
      End Impl_core_marker_Copy_for_spl_token_2022_extension_confidential_transfer_instruction_TransferWithSplitProofsInstructionData.
      
      Module Impl_core_fmt_Debug_for_spl_token_2022_extension_confidential_transfer_instruction_TransferWithSplitProofsInstructionData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::TransferWithSplitProofsInstructionData".
        
        (* Debug *)
        Definition fmt (τ : list Ty.t) (α : list Value.t) : M :=
          match τ, α with
          | [], [ self; f ] =>
            ltac:(M.monadic
              (let self := M.alloc (| self |) in
              let f := M.alloc (| f |) in
              M.call_closure (|
                M.get_associated_function (|
                  Ty.path "core::fmt::Formatter",
                  "debug_struct_field4_finish",
                  []
                |),
                [
                  M.read (| f |);
                  M.read (| Value.String "TransferWithSplitProofsInstructionData" |);
                  M.read (| Value.String "new_source_decryptable_available_balance" |);
                  (* Unsize *)
                  M.pointer_coercion
                    (M.SubPointer.get_struct_record_field (|
                      M.read (| self |),
                      "spl_token_2022::extension::confidential_transfer::instruction::TransferWithSplitProofsInstructionData",
                      "new_source_decryptable_available_balance"
                    |));
                  M.read (| Value.String "no_op_on_uninitialized_split_context_state" |);
                  (* Unsize *)
                  M.pointer_coercion
                    (M.SubPointer.get_struct_record_field (|
                      M.read (| self |),
                      "spl_token_2022::extension::confidential_transfer::instruction::TransferWithSplitProofsInstructionData",
                      "no_op_on_uninitialized_split_context_state"
                    |));
                  M.read (| Value.String "close_split_context_state_on_execution" |);
                  (* Unsize *)
                  M.pointer_coercion
                    (M.SubPointer.get_struct_record_field (|
                      M.read (| self |),
                      "spl_token_2022::extension::confidential_transfer::instruction::TransferWithSplitProofsInstructionData",
                      "close_split_context_state_on_execution"
                    |));
                  M.read (| Value.String "source_decrypt_handles" |);
                  (* Unsize *)
                  M.pointer_coercion
                    (M.alloc (|
                      M.SubPointer.get_struct_record_field (|
                        M.read (| self |),
                        "spl_token_2022::extension::confidential_transfer::instruction::TransferWithSplitProofsInstructionData",
                        "source_decrypt_handles"
                      |)
                    |))
                ]
              |)))
          | _, _ => M.impossible
          end.
        
        Axiom Implements :
          M.IsTraitInstance
            "core::fmt::Debug"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [ ("fmt", InstanceField.Method fmt) ].
      End Impl_core_fmt_Debug_for_spl_token_2022_extension_confidential_transfer_instruction_TransferWithSplitProofsInstructionData.
      
      Module Impl_core_marker_StructuralPartialEq_for_spl_token_2022_extension_confidential_transfer_instruction_TransferWithSplitProofsInstructionData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::TransferWithSplitProofsInstructionData".
        
        Axiom Implements :
          M.IsTraitInstance
            "core::marker::StructuralPartialEq"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [].
      End Impl_core_marker_StructuralPartialEq_for_spl_token_2022_extension_confidential_transfer_instruction_TransferWithSplitProofsInstructionData.
      
      Module Impl_core_cmp_PartialEq_for_spl_token_2022_extension_confidential_transfer_instruction_TransferWithSplitProofsInstructionData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::TransferWithSplitProofsInstructionData".
        
        (* PartialEq *)
        Definition eq (τ : list Ty.t) (α : list Value.t) : M :=
          match τ, α with
          | [], [ self; other ] =>
            ltac:(M.monadic
              (let self := M.alloc (| self |) in
              let other := M.alloc (| other |) in
              LogicalOp.and (|
                LogicalOp.and (|
                  LogicalOp.and (|
                    M.call_closure (|
                      M.get_trait_method (|
                        "core::cmp::PartialEq",
                        Ty.path
                          "solana_zk_token_sdk::zk_token_elgamal::pod::auth_encryption::AeCiphertext",
                        [
                          Ty.path
                            "solana_zk_token_sdk::zk_token_elgamal::pod::auth_encryption::AeCiphertext"
                        ],
                        "eq",
                        []
                      |),
                      [
                        M.SubPointer.get_struct_record_field (|
                          M.read (| self |),
                          "spl_token_2022::extension::confidential_transfer::instruction::TransferWithSplitProofsInstructionData",
                          "new_source_decryptable_available_balance"
                        |);
                        M.SubPointer.get_struct_record_field (|
                          M.read (| other |),
                          "spl_token_2022::extension::confidential_transfer::instruction::TransferWithSplitProofsInstructionData",
                          "new_source_decryptable_available_balance"
                        |)
                      ]
                    |),
                    ltac:(M.monadic
                      (M.call_closure (|
                        M.get_trait_method (|
                          "core::cmp::PartialEq",
                          Ty.path "spl_pod::primitives::PodBool",
                          [ Ty.path "spl_pod::primitives::PodBool" ],
                          "eq",
                          []
                        |),
                        [
                          M.SubPointer.get_struct_record_field (|
                            M.read (| self |),
                            "spl_token_2022::extension::confidential_transfer::instruction::TransferWithSplitProofsInstructionData",
                            "no_op_on_uninitialized_split_context_state"
                          |);
                          M.SubPointer.get_struct_record_field (|
                            M.read (| other |),
                            "spl_token_2022::extension::confidential_transfer::instruction::TransferWithSplitProofsInstructionData",
                            "no_op_on_uninitialized_split_context_state"
                          |)
                        ]
                      |)))
                  |),
                  ltac:(M.monadic
                    (M.call_closure (|
                      M.get_trait_method (|
                        "core::cmp::PartialEq",
                        Ty.path "spl_pod::primitives::PodBool",
                        [ Ty.path "spl_pod::primitives::PodBool" ],
                        "eq",
                        []
                      |),
                      [
                        M.SubPointer.get_struct_record_field (|
                          M.read (| self |),
                          "spl_token_2022::extension::confidential_transfer::instruction::TransferWithSplitProofsInstructionData",
                          "close_split_context_state_on_execution"
                        |);
                        M.SubPointer.get_struct_record_field (|
                          M.read (| other |),
                          "spl_token_2022::extension::confidential_transfer::instruction::TransferWithSplitProofsInstructionData",
                          "close_split_context_state_on_execution"
                        |)
                      ]
                    |)))
                |),
                ltac:(M.monadic
                  (M.call_closure (|
                    M.get_trait_method (|
                      "core::cmp::PartialEq",
                      Ty.path
                        "spl_token_2022::extension::confidential_transfer::ciphertext_extraction::SourceDecryptHandles",
                      [
                        Ty.path
                          "spl_token_2022::extension::confidential_transfer::ciphertext_extraction::SourceDecryptHandles"
                      ],
                      "eq",
                      []
                    |),
                    [
                      M.SubPointer.get_struct_record_field (|
                        M.read (| self |),
                        "spl_token_2022::extension::confidential_transfer::instruction::TransferWithSplitProofsInstructionData",
                        "source_decrypt_handles"
                      |);
                      M.SubPointer.get_struct_record_field (|
                        M.read (| other |),
                        "spl_token_2022::extension::confidential_transfer::instruction::TransferWithSplitProofsInstructionData",
                        "source_decrypt_handles"
                      |)
                    ]
                  |)))
              |)))
          | _, _ => M.impossible
          end.
        
        Axiom Implements :
          M.IsTraitInstance
            "core::cmp::PartialEq"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [ ("eq", InstanceField.Method eq) ].
      End Impl_core_cmp_PartialEq_for_spl_token_2022_extension_confidential_transfer_instruction_TransferWithSplitProofsInstructionData.
      
      Module Impl_bytemuck_pod_Pod_for_spl_token_2022_extension_confidential_transfer_instruction_TransferWithSplitProofsInstructionData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::TransferWithSplitProofsInstructionData".
        
        Axiom Implements :
          M.IsTraitInstance
            "bytemuck::pod::Pod"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [].
      End Impl_bytemuck_pod_Pod_for_spl_token_2022_extension_confidential_transfer_instruction_TransferWithSplitProofsInstructionData.
      
      Module Impl_bytemuck_zeroable_Zeroable_for_spl_token_2022_extension_confidential_transfer_instruction_TransferWithSplitProofsInstructionData.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::TransferWithSplitProofsInstructionData".
        
        Axiom Implements :
          M.IsTraitInstance
            "bytemuck::zeroable::Zeroable"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [].
      End Impl_bytemuck_zeroable_Zeroable_for_spl_token_2022_extension_confidential_transfer_instruction_TransferWithSplitProofsInstructionData.
      
      (* StructRecord
        {
          name := "TransferSplitContextStateAccounts";
          ty_params := [];
          fields :=
            [
              ("equality_proof",
                Ty.apply (Ty.path "&") [ Ty.path "solana_program::pubkey::Pubkey" ]);
              ("ciphertext_validity_proof",
                Ty.apply (Ty.path "&") [ Ty.path "solana_program::pubkey::Pubkey" ]);
              ("range_proof", Ty.apply (Ty.path "&") [ Ty.path "solana_program::pubkey::Pubkey" ]);
              ("authority", Ty.apply (Ty.path "&") [ Ty.path "solana_program::pubkey::Pubkey" ]);
              ("no_op_on_uninitialized_split_context_state", Ty.path "bool");
              ("close_split_context_state_accounts",
                Ty.apply
                  (Ty.path "core::option::Option")
                  [
                    Ty.path
                      "spl_token_2022::extension::confidential_transfer::instruction::CloseSplitContextStateAccounts"
                  ])
            ];
        } *)
      
      Module Impl_core_clone_Clone_for_spl_token_2022_extension_confidential_transfer_instruction_TransferSplitContextStateAccounts.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::TransferSplitContextStateAccounts".
        
        (* Clone *)
        Definition clone (τ : list Ty.t) (α : list Value.t) : M :=
          match τ, α with
          | [], [ self ] =>
            ltac:(M.monadic
              (let self := M.alloc (| self |) in
              M.read (|
                M.match_operator (|
                  Value.DeclaredButUndefined,
                  [
                    fun γ =>
                      ltac:(M.monadic
                        (M.match_operator (|
                          Value.DeclaredButUndefined,
                          [
                            fun γ =>
                              ltac:(M.monadic
                                (M.match_operator (|
                                  Value.DeclaredButUndefined,
                                  [
                                    fun γ =>
                                      ltac:(M.monadic
                                        (M.match_operator (|
                                          Value.DeclaredButUndefined,
                                          [
                                            fun γ =>
                                              ltac:(M.monadic
                                                (M.match_operator (|
                                                  Value.DeclaredButUndefined,
                                                  [
                                                    fun γ =>
                                                      ltac:(M.monadic
                                                        (M.match_operator (|
                                                          Value.DeclaredButUndefined,
                                                          [
                                                            fun γ =>
                                                              ltac:(M.monadic (M.read (| self |)))
                                                          ]
                                                        |)))
                                                  ]
                                                |)))
                                          ]
                                        |)))
                                  ]
                                |)))
                          ]
                        |)))
                  ]
                |)
              |)))
          | _, _ => M.impossible
          end.
        
        Axiom Implements :
          M.IsTraitInstance
            "core::clone::Clone"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [ ("clone", InstanceField.Method clone) ].
      End Impl_core_clone_Clone_for_spl_token_2022_extension_confidential_transfer_instruction_TransferSplitContextStateAccounts.
      
      Module Impl_core_marker_Copy_for_spl_token_2022_extension_confidential_transfer_instruction_TransferSplitContextStateAccounts.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::TransferSplitContextStateAccounts".
        
        Axiom Implements :
          M.IsTraitInstance
            "core::marker::Copy"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [].
      End Impl_core_marker_Copy_for_spl_token_2022_extension_confidential_transfer_instruction_TransferSplitContextStateAccounts.
      
      (* StructRecord
        {
          name := "TransferWithFeeSplitContextStateAccounts";
          ty_params := [];
          fields :=
            [
              ("equality_proof",
                Ty.apply (Ty.path "&") [ Ty.path "solana_program::pubkey::Pubkey" ]);
              ("transfer_amount_ciphertext_validity_proof",
                Ty.apply (Ty.path "&") [ Ty.path "solana_program::pubkey::Pubkey" ]);
              ("fee_sigma_proof",
                Ty.apply (Ty.path "&") [ Ty.path "solana_program::pubkey::Pubkey" ]);
              ("fee_ciphertext_validity_proof",
                Ty.apply (Ty.path "&") [ Ty.path "solana_program::pubkey::Pubkey" ]);
              ("range_proof", Ty.apply (Ty.path "&") [ Ty.path "solana_program::pubkey::Pubkey" ]);
              ("authority", Ty.apply (Ty.path "&") [ Ty.path "solana_program::pubkey::Pubkey" ]);
              ("no_op_on_uninitialized_split_context_state", Ty.path "bool");
              ("close_split_context_state_accounts",
                Ty.apply
                  (Ty.path "core::option::Option")
                  [
                    Ty.path
                      "spl_token_2022::extension::confidential_transfer::instruction::CloseSplitContextStateAccounts"
                  ])
            ];
        } *)
      
      Module Impl_core_clone_Clone_for_spl_token_2022_extension_confidential_transfer_instruction_TransferWithFeeSplitContextStateAccounts.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::TransferWithFeeSplitContextStateAccounts".
        
        (* Clone *)
        Definition clone (τ : list Ty.t) (α : list Value.t) : M :=
          match τ, α with
          | [], [ self ] =>
            ltac:(M.monadic
              (let self := M.alloc (| self |) in
              M.read (|
                M.match_operator (|
                  Value.DeclaredButUndefined,
                  [
                    fun γ =>
                      ltac:(M.monadic
                        (M.match_operator (|
                          Value.DeclaredButUndefined,
                          [
                            fun γ =>
                              ltac:(M.monadic
                                (M.match_operator (|
                                  Value.DeclaredButUndefined,
                                  [
                                    fun γ =>
                                      ltac:(M.monadic
                                        (M.match_operator (|
                                          Value.DeclaredButUndefined,
                                          [
                                            fun γ =>
                                              ltac:(M.monadic
                                                (M.match_operator (|
                                                  Value.DeclaredButUndefined,
                                                  [
                                                    fun γ =>
                                                      ltac:(M.monadic
                                                        (M.match_operator (|
                                                          Value.DeclaredButUndefined,
                                                          [
                                                            fun γ =>
                                                              ltac:(M.monadic
                                                                (M.match_operator (|
                                                                  Value.DeclaredButUndefined,
                                                                  [
                                                                    fun γ =>
                                                                      ltac:(M.monadic
                                                                        (M.match_operator (|
                                                                          Value.DeclaredButUndefined,
                                                                          [
                                                                            fun γ =>
                                                                              ltac:(M.monadic
                                                                                (M.read (| self |)))
                                                                          ]
                                                                        |)))
                                                                  ]
                                                                |)))
                                                          ]
                                                        |)))
                                                  ]
                                                |)))
                                          ]
                                        |)))
                                  ]
                                |)))
                          ]
                        |)))
                  ]
                |)
              |)))
          | _, _ => M.impossible
          end.
        
        Axiom Implements :
          M.IsTraitInstance
            "core::clone::Clone"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [ ("clone", InstanceField.Method clone) ].
      End Impl_core_clone_Clone_for_spl_token_2022_extension_confidential_transfer_instruction_TransferWithFeeSplitContextStateAccounts.
      
      Module Impl_core_marker_Copy_for_spl_token_2022_extension_confidential_transfer_instruction_TransferWithFeeSplitContextStateAccounts.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::TransferWithFeeSplitContextStateAccounts".
        
        Axiom Implements :
          M.IsTraitInstance
            "core::marker::Copy"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [].
      End Impl_core_marker_Copy_for_spl_token_2022_extension_confidential_transfer_instruction_TransferWithFeeSplitContextStateAccounts.
      
      (* StructRecord
        {
          name := "CloseSplitContextStateAccounts";
          ty_params := [];
          fields :=
            [
              ("lamport_destination",
                Ty.apply (Ty.path "&") [ Ty.path "solana_program::pubkey::Pubkey" ]);
              ("zk_token_proof_program",
                Ty.apply (Ty.path "&") [ Ty.path "solana_program::pubkey::Pubkey" ])
            ];
        } *)
      
      Module Impl_core_clone_Clone_for_spl_token_2022_extension_confidential_transfer_instruction_CloseSplitContextStateAccounts.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::CloseSplitContextStateAccounts".
        
        (* Clone *)
        Definition clone (τ : list Ty.t) (α : list Value.t) : M :=
          match τ, α with
          | [], [ self ] =>
            ltac:(M.monadic
              (let self := M.alloc (| self |) in
              M.read (|
                M.match_operator (|
                  Value.DeclaredButUndefined,
                  [
                    fun γ =>
                      ltac:(M.monadic
                        (M.match_operator (|
                          Value.DeclaredButUndefined,
                          [ fun γ => ltac:(M.monadic (M.read (| self |))) ]
                        |)))
                  ]
                |)
              |)))
          | _, _ => M.impossible
          end.
        
        Axiom Implements :
          M.IsTraitInstance
            "core::clone::Clone"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [ ("clone", InstanceField.Method clone) ].
      End Impl_core_clone_Clone_for_spl_token_2022_extension_confidential_transfer_instruction_CloseSplitContextStateAccounts.
      
      Module Impl_core_marker_Copy_for_spl_token_2022_extension_confidential_transfer_instruction_CloseSplitContextStateAccounts.
        Definition Self : Ty.t :=
          Ty.path
            "spl_token_2022::extension::confidential_transfer::instruction::CloseSplitContextStateAccounts".
        
        Axiom Implements :
          M.IsTraitInstance
            "core::marker::Copy"
            Self
            (* Trait polymorphic types *) []
            (* Instance *) [].
      End Impl_core_marker_Copy_for_spl_token_2022_extension_confidential_transfer_instruction_CloseSplitContextStateAccounts.
      
      (*
      pub fn initialize_mint(
          token_program_id: &Pubkey,
          mint: &Pubkey,
          authority: Option<Pubkey>,
          auto_approve_new_accounts: bool,
          auditor_elgamal_pubkey: Option<ElGamalPubkey>,
      ) -> Result<Instruction, ProgramError> {
          check_program_account(token_program_id)?;
          let accounts = vec![AccountMeta::new( *mint, false)];
      
          Ok(encode_instruction(
              token_program_id,
              accounts,
              TokenInstruction::ConfidentialTransferExtension,
              ConfidentialTransferInstruction::InitializeMint,
              &InitializeMintData {
                  authority: authority.try_into()?,
                  auto_approve_new_accounts: auto_approve_new_accounts.into(),
                  auditor_elgamal_pubkey: auditor_elgamal_pubkey.try_into()?,
              },
          ))
      }
      *)
      Definition initialize_mint (τ : list Ty.t) (α : list Value.t) : M :=
        match τ, α with
        | [],
            [ token_program_id; mint; authority; auto_approve_new_accounts; auditor_elgamal_pubkey
            ] =>
          ltac:(M.monadic
            (let token_program_id := M.alloc (| token_program_id |) in
            let mint := M.alloc (| mint |) in
            let authority := M.alloc (| authority |) in
            let auto_approve_new_accounts := M.alloc (| auto_approve_new_accounts |) in
            let auditor_elgamal_pubkey := M.alloc (| auditor_elgamal_pubkey |) in
            M.catch_return (|
              ltac:(M.monadic
                (M.read (|
                  let _ :=
                    M.match_operator (|
                      M.alloc (|
                        M.call_closure (|
                          M.get_trait_method (|
                            "core::ops::try_trait::Try",
                            Ty.apply
                              (Ty.path "core::result::Result")
                              [ Ty.tuple []; Ty.path "solana_program::program_error::ProgramError"
                              ],
                            [],
                            "branch",
                            []
                          |),
                          [
                            M.call_closure (|
                              M.get_function (| "spl_token_2022::check_program_account", [] |),
                              [ M.read (| token_program_id |) ]
                            |)
                          ]
                        |)
                      |),
                      [
                        fun γ =>
                          ltac:(M.monadic
                            (let γ0_0 :=
                              M.SubPointer.get_struct_tuple_field (|
                                γ,
                                "core::ops::control_flow::ControlFlow::Break",
                                0
                              |) in
                            let residual := M.copy (| γ0_0 |) in
                            M.alloc (|
                              M.never_to_any (|
                                M.read (|
                                  M.return_ (|
                                    M.call_closure (|
                                      M.get_trait_method (|
                                        "core::ops::try_trait::FromResidual",
                                        Ty.apply
                                          (Ty.path "core::result::Result")
                                          [
                                            Ty.path "solana_program::instruction::Instruction";
                                            Ty.path "solana_program::program_error::ProgramError"
                                          ],
                                        [
                                          Ty.apply
                                            (Ty.path "core::result::Result")
                                            [
                                              Ty.path "core::convert::Infallible";
                                              Ty.path "solana_program::program_error::ProgramError"
                                            ]
                                        ],
                                        "from_residual",
                                        []
                                      |),
                                      [ M.read (| residual |) ]
                                    |)
                                  |)
                                |)
                              |)
                            |)));
                        fun γ =>
                          ltac:(M.monadic
                            (let γ0_0 :=
                              M.SubPointer.get_struct_tuple_field (|
                                γ,
                                "core::ops::control_flow::ControlFlow::Continue",
                                0
                              |) in
                            let val := M.copy (| γ0_0 |) in
                            val))
                      ]
                    |) in
                  let accounts :=
                    M.alloc (|
                      M.call_closure (|
                        M.get_associated_function (|
                          Ty.apply
                            (Ty.path "slice")
                            [ Ty.path "solana_program::instruction::AccountMeta" ],
                          "into_vec",
                          [ Ty.path "alloc::alloc::Global" ]
                        |),
                        [
                          (* Unsize *)
                          M.pointer_coercion
                            (M.read (|
                              M.call_closure (|
                                M.get_associated_function (|
                                  Ty.apply
                                    (Ty.path "alloc::boxed::Box")
                                    [
                                      Ty.apply
                                        (Ty.path "array")
                                        [ Ty.path "solana_program::instruction::AccountMeta" ];
                                      Ty.path "alloc::alloc::Global"
                                    ],
                                  "new",
                                  []
                                |),
                                [
                                  M.alloc (|
                                    Value.Array
                                      [
                                        M.call_closure (|
                                          M.get_associated_function (|
                                            Ty.path "solana_program::instruction::AccountMeta",
                                            "new",
                                            []
                                          |),
                                          [ M.read (| M.read (| mint |) |); Value.Bool false ]
                                        |)
                                      ]
                                  |)
                                ]
                              |)
                            |))
                        ]
                      |)
                    |) in
                  M.alloc (|
                    Value.StructTuple
                      "core::result::Result::Ok"
                      [
                        M.call_closure (|
                          M.get_function (|
                            "spl_token_2022::instruction::encode_instruction",
                            [
                              Ty.path
                                "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction";
                              Ty.path
                                "spl_token_2022::extension::confidential_transfer::instruction::InitializeMintData"
                            ]
                          |),
                          [
                            M.read (| token_program_id |);
                            M.read (| accounts |);
                            Value.StructTuple
                              "spl_token_2022::instruction::TokenInstruction::ConfidentialTransferExtension"
                              [];
                            Value.StructTuple
                              "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction::InitializeMint"
                              [];
                            M.alloc (|
                              Value.StructRecord
                                "spl_token_2022::extension::confidential_transfer::instruction::InitializeMintData"
                                [
                                  ("authority",
                                    M.read (|
                                      M.match_operator (|
                                        M.alloc (|
                                          M.call_closure (|
                                            M.get_trait_method (|
                                              "core::ops::try_trait::Try",
                                              Ty.apply
                                                (Ty.path "core::result::Result")
                                                [
                                                  Ty.path
                                                    "spl_pod::optional_keys::OptionalNonZeroPubkey";
                                                  Ty.path
                                                    "solana_program::program_error::ProgramError"
                                                ],
                                              [],
                                              "branch",
                                              []
                                            |),
                                            [
                                              M.call_closure (|
                                                M.get_trait_method (|
                                                  "core::convert::TryInto",
                                                  Ty.apply
                                                    (Ty.path "core::option::Option")
                                                    [ Ty.path "solana_program::pubkey::Pubkey" ],
                                                  [
                                                    Ty.path
                                                      "spl_pod::optional_keys::OptionalNonZeroPubkey"
                                                  ],
                                                  "try_into",
                                                  []
                                                |),
                                                [ M.read (| authority |) ]
                                              |)
                                            ]
                                          |)
                                        |),
                                        [
                                          fun γ =>
                                            ltac:(M.monadic
                                              (let γ0_0 :=
                                                M.SubPointer.get_struct_tuple_field (|
                                                  γ,
                                                  "core::ops::control_flow::ControlFlow::Break",
                                                  0
                                                |) in
                                              let residual := M.copy (| γ0_0 |) in
                                              M.alloc (|
                                                M.never_to_any (|
                                                  M.read (|
                                                    M.return_ (|
                                                      M.call_closure (|
                                                        M.get_trait_method (|
                                                          "core::ops::try_trait::FromResidual",
                                                          Ty.apply
                                                            (Ty.path "core::result::Result")
                                                            [
                                                              Ty.path
                                                                "solana_program::instruction::Instruction";
                                                              Ty.path
                                                                "solana_program::program_error::ProgramError"
                                                            ],
                                                          [
                                                            Ty.apply
                                                              (Ty.path "core::result::Result")
                                                              [
                                                                Ty.path "core::convert::Infallible";
                                                                Ty.path
                                                                  "solana_program::program_error::ProgramError"
                                                              ]
                                                          ],
                                                          "from_residual",
                                                          []
                                                        |),
                                                        [ M.read (| residual |) ]
                                                      |)
                                                    |)
                                                  |)
                                                |)
                                              |)));
                                          fun γ =>
                                            ltac:(M.monadic
                                              (let γ0_0 :=
                                                M.SubPointer.get_struct_tuple_field (|
                                                  γ,
                                                  "core::ops::control_flow::ControlFlow::Continue",
                                                  0
                                                |) in
                                              let val := M.copy (| γ0_0 |) in
                                              val))
                                        ]
                                      |)
                                    |));
                                  ("auto_approve_new_accounts",
                                    M.call_closure (|
                                      M.get_trait_method (|
                                        "core::convert::Into",
                                        Ty.path "bool",
                                        [ Ty.path "spl_pod::primitives::PodBool" ],
                                        "into",
                                        []
                                      |),
                                      [ M.read (| auto_approve_new_accounts |) ]
                                    |));
                                  ("auditor_elgamal_pubkey",
                                    M.read (|
                                      M.match_operator (|
                                        M.alloc (|
                                          M.call_closure (|
                                            M.get_trait_method (|
                                              "core::ops::try_trait::Try",
                                              Ty.apply
                                                (Ty.path "core::result::Result")
                                                [
                                                  Ty.path
                                                    "spl_pod::optional_keys::OptionalNonZeroElGamalPubkey";
                                                  Ty.path
                                                    "solana_program::program_error::ProgramError"
                                                ],
                                              [],
                                              "branch",
                                              []
                                            |),
                                            [
                                              M.call_closure (|
                                                M.get_trait_method (|
                                                  "core::convert::TryInto",
                                                  Ty.apply
                                                    (Ty.path "core::option::Option")
                                                    [
                                                      Ty.path
                                                        "solana_zk_token_sdk::zk_token_elgamal::pod::elgamal::ElGamalPubkey"
                                                    ],
                                                  [
                                                    Ty.path
                                                      "spl_pod::optional_keys::OptionalNonZeroElGamalPubkey"
                                                  ],
                                                  "try_into",
                                                  []
                                                |),
                                                [ M.read (| auditor_elgamal_pubkey |) ]
                                              |)
                                            ]
                                          |)
                                        |),
                                        [
                                          fun γ =>
                                            ltac:(M.monadic
                                              (let γ0_0 :=
                                                M.SubPointer.get_struct_tuple_field (|
                                                  γ,
                                                  "core::ops::control_flow::ControlFlow::Break",
                                                  0
                                                |) in
                                              let residual := M.copy (| γ0_0 |) in
                                              M.alloc (|
                                                M.never_to_any (|
                                                  M.read (|
                                                    M.return_ (|
                                                      M.call_closure (|
                                                        M.get_trait_method (|
                                                          "core::ops::try_trait::FromResidual",
                                                          Ty.apply
                                                            (Ty.path "core::result::Result")
                                                            [
                                                              Ty.path
                                                                "solana_program::instruction::Instruction";
                                                              Ty.path
                                                                "solana_program::program_error::ProgramError"
                                                            ],
                                                          [
                                                            Ty.apply
                                                              (Ty.path "core::result::Result")
                                                              [
                                                                Ty.path "core::convert::Infallible";
                                                                Ty.path
                                                                  "solana_program::program_error::ProgramError"
                                                              ]
                                                          ],
                                                          "from_residual",
                                                          []
                                                        |),
                                                        [ M.read (| residual |) ]
                                                      |)
                                                    |)
                                                  |)
                                                |)
                                              |)));
                                          fun γ =>
                                            ltac:(M.monadic
                                              (let γ0_0 :=
                                                M.SubPointer.get_struct_tuple_field (|
                                                  γ,
                                                  "core::ops::control_flow::ControlFlow::Continue",
                                                  0
                                                |) in
                                              let val := M.copy (| γ0_0 |) in
                                              val))
                                        ]
                                      |)
                                    |))
                                ]
                            |)
                          ]
                        |)
                      ]
                  |)
                |)))
            |)))
        | _, _ => M.impossible
        end.
      
      (*
      pub fn update_mint(
          token_program_id: &Pubkey,
          mint: &Pubkey,
          authority: &Pubkey,
          multisig_signers: &[&Pubkey],
          auto_approve_new_accounts: bool,
          auditor_elgamal_pubkey: Option<ElGamalPubkey>,
      ) -> Result<Instruction, ProgramError> {
          check_program_account(token_program_id)?;
          let mut accounts = vec![
              AccountMeta::new( *mint, false),
              AccountMeta::new_readonly( *authority, multisig_signers.is_empty()),
          ];
          for multisig_signer in multisig_signers.iter() {
              accounts.push(AccountMeta::new_readonly( **multisig_signer, true));
          }
          Ok(encode_instruction(
              token_program_id,
              accounts,
              TokenInstruction::ConfidentialTransferExtension,
              ConfidentialTransferInstruction::UpdateMint,
              &UpdateMintData {
                  auto_approve_new_accounts: auto_approve_new_accounts.into(),
                  auditor_elgamal_pubkey: auditor_elgamal_pubkey.try_into()?,
              },
          ))
      }
      *)
      Definition update_mint (τ : list Ty.t) (α : list Value.t) : M :=
        match τ, α with
        | [],
            [
              token_program_id;
              mint;
              authority;
              multisig_signers;
              auto_approve_new_accounts;
              auditor_elgamal_pubkey
            ] =>
          ltac:(M.monadic
            (let token_program_id := M.alloc (| token_program_id |) in
            let mint := M.alloc (| mint |) in
            let authority := M.alloc (| authority |) in
            let multisig_signers := M.alloc (| multisig_signers |) in
            let auto_approve_new_accounts := M.alloc (| auto_approve_new_accounts |) in
            let auditor_elgamal_pubkey := M.alloc (| auditor_elgamal_pubkey |) in
            M.catch_return (|
              ltac:(M.monadic
                (M.read (|
                  let _ :=
                    M.match_operator (|
                      M.alloc (|
                        M.call_closure (|
                          M.get_trait_method (|
                            "core::ops::try_trait::Try",
                            Ty.apply
                              (Ty.path "core::result::Result")
                              [ Ty.tuple []; Ty.path "solana_program::program_error::ProgramError"
                              ],
                            [],
                            "branch",
                            []
                          |),
                          [
                            M.call_closure (|
                              M.get_function (| "spl_token_2022::check_program_account", [] |),
                              [ M.read (| token_program_id |) ]
                            |)
                          ]
                        |)
                      |),
                      [
                        fun γ =>
                          ltac:(M.monadic
                            (let γ0_0 :=
                              M.SubPointer.get_struct_tuple_field (|
                                γ,
                                "core::ops::control_flow::ControlFlow::Break",
                                0
                              |) in
                            let residual := M.copy (| γ0_0 |) in
                            M.alloc (|
                              M.never_to_any (|
                                M.read (|
                                  M.return_ (|
                                    M.call_closure (|
                                      M.get_trait_method (|
                                        "core::ops::try_trait::FromResidual",
                                        Ty.apply
                                          (Ty.path "core::result::Result")
                                          [
                                            Ty.path "solana_program::instruction::Instruction";
                                            Ty.path "solana_program::program_error::ProgramError"
                                          ],
                                        [
                                          Ty.apply
                                            (Ty.path "core::result::Result")
                                            [
                                              Ty.path "core::convert::Infallible";
                                              Ty.path "solana_program::program_error::ProgramError"
                                            ]
                                        ],
                                        "from_residual",
                                        []
                                      |),
                                      [ M.read (| residual |) ]
                                    |)
                                  |)
                                |)
                              |)
                            |)));
                        fun γ =>
                          ltac:(M.monadic
                            (let γ0_0 :=
                              M.SubPointer.get_struct_tuple_field (|
                                γ,
                                "core::ops::control_flow::ControlFlow::Continue",
                                0
                              |) in
                            let val := M.copy (| γ0_0 |) in
                            val))
                      ]
                    |) in
                  let accounts :=
                    M.alloc (|
                      M.call_closure (|
                        M.get_associated_function (|
                          Ty.apply
                            (Ty.path "slice")
                            [ Ty.path "solana_program::instruction::AccountMeta" ],
                          "into_vec",
                          [ Ty.path "alloc::alloc::Global" ]
                        |),
                        [
                          (* Unsize *)
                          M.pointer_coercion
                            (M.read (|
                              M.call_closure (|
                                M.get_associated_function (|
                                  Ty.apply
                                    (Ty.path "alloc::boxed::Box")
                                    [
                                      Ty.apply
                                        (Ty.path "array")
                                        [ Ty.path "solana_program::instruction::AccountMeta" ];
                                      Ty.path "alloc::alloc::Global"
                                    ],
                                  "new",
                                  []
                                |),
                                [
                                  M.alloc (|
                                    Value.Array
                                      [
                                        M.call_closure (|
                                          M.get_associated_function (|
                                            Ty.path "solana_program::instruction::AccountMeta",
                                            "new",
                                            []
                                          |),
                                          [ M.read (| M.read (| mint |) |); Value.Bool false ]
                                        |);
                                        M.call_closure (|
                                          M.get_associated_function (|
                                            Ty.path "solana_program::instruction::AccountMeta",
                                            "new_readonly",
                                            []
                                          |),
                                          [
                                            M.read (| M.read (| authority |) |);
                                            M.call_closure (|
                                              M.get_associated_function (|
                                                Ty.apply
                                                  (Ty.path "slice")
                                                  [
                                                    Ty.apply
                                                      (Ty.path "&")
                                                      [ Ty.path "solana_program::pubkey::Pubkey" ]
                                                  ],
                                                "is_empty",
                                                []
                                              |),
                                              [ M.read (| multisig_signers |) ]
                                            |)
                                          ]
                                        |)
                                      ]
                                  |)
                                ]
                              |)
                            |))
                        ]
                      |)
                    |) in
                  let _ :=
                    M.use
                      (M.match_operator (|
                        M.alloc (|
                          M.call_closure (|
                            M.get_trait_method (|
                              "core::iter::traits::collect::IntoIterator",
                              Ty.apply
                                (Ty.path "core::slice::iter::Iter")
                                [
                                  Ty.apply
                                    (Ty.path "&")
                                    [ Ty.path "solana_program::pubkey::Pubkey" ]
                                ],
                              [],
                              "into_iter",
                              []
                            |),
                            [
                              M.call_closure (|
                                M.get_associated_function (|
                                  Ty.apply
                                    (Ty.path "slice")
                                    [
                                      Ty.apply
                                        (Ty.path "&")
                                        [ Ty.path "solana_program::pubkey::Pubkey" ]
                                    ],
                                  "iter",
                                  []
                                |),
                                [ M.read (| multisig_signers |) ]
                              |)
                            ]
                          |)
                        |),
                        [
                          fun γ =>
                            ltac:(M.monadic
                              (let iter := M.copy (| γ |) in
                              M.loop (|
                                ltac:(M.monadic
                                  (let _ :=
                                    M.match_operator (|
                                      M.alloc (|
                                        M.call_closure (|
                                          M.get_trait_method (|
                                            "core::iter::traits::iterator::Iterator",
                                            Ty.apply
                                              (Ty.path "core::slice::iter::Iter")
                                              [
                                                Ty.apply
                                                  (Ty.path "&")
                                                  [ Ty.path "solana_program::pubkey::Pubkey" ]
                                              ],
                                            [],
                                            "next",
                                            []
                                          |),
                                          [ iter ]
                                        |)
                                      |),
                                      [
                                        fun γ =>
                                          ltac:(M.monadic
                                            (M.alloc (|
                                              M.never_to_any (| M.read (| M.break (||) |) |)
                                            |)));
                                        fun γ =>
                                          ltac:(M.monadic
                                            (let γ0_0 :=
                                              M.SubPointer.get_struct_tuple_field (|
                                                γ,
                                                "core::option::Option::Some",
                                                0
                                              |) in
                                            let multisig_signer := M.copy (| γ0_0 |) in
                                            let _ :=
                                              M.alloc (|
                                                M.call_closure (|
                                                  M.get_associated_function (|
                                                    Ty.apply
                                                      (Ty.path "alloc::vec::Vec")
                                                      [
                                                        Ty.path
                                                          "solana_program::instruction::AccountMeta";
                                                        Ty.path "alloc::alloc::Global"
                                                      ],
                                                    "push",
                                                    []
                                                  |),
                                                  [
                                                    accounts;
                                                    M.call_closure (|
                                                      M.get_associated_function (|
                                                        Ty.path
                                                          "solana_program::instruction::AccountMeta",
                                                        "new_readonly",
                                                        []
                                                      |),
                                                      [
                                                        M.read (|
                                                          M.read (| M.read (| multisig_signer |) |)
                                                        |);
                                                        Value.Bool true
                                                      ]
                                                    |)
                                                  ]
                                                |)
                                              |) in
                                            M.alloc (| Value.Tuple [] |)))
                                      ]
                                    |) in
                                  M.alloc (| Value.Tuple [] |)))
                              |)))
                        ]
                      |)) in
                  M.alloc (|
                    Value.StructTuple
                      "core::result::Result::Ok"
                      [
                        M.call_closure (|
                          M.get_function (|
                            "spl_token_2022::instruction::encode_instruction",
                            [
                              Ty.path
                                "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction";
                              Ty.path
                                "spl_token_2022::extension::confidential_transfer::instruction::UpdateMintData"
                            ]
                          |),
                          [
                            M.read (| token_program_id |);
                            M.read (| accounts |);
                            Value.StructTuple
                              "spl_token_2022::instruction::TokenInstruction::ConfidentialTransferExtension"
                              [];
                            Value.StructTuple
                              "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction::UpdateMint"
                              [];
                            M.alloc (|
                              Value.StructRecord
                                "spl_token_2022::extension::confidential_transfer::instruction::UpdateMintData"
                                [
                                  ("auto_approve_new_accounts",
                                    M.call_closure (|
                                      M.get_trait_method (|
                                        "core::convert::Into",
                                        Ty.path "bool",
                                        [ Ty.path "spl_pod::primitives::PodBool" ],
                                        "into",
                                        []
                                      |),
                                      [ M.read (| auto_approve_new_accounts |) ]
                                    |));
                                  ("auditor_elgamal_pubkey",
                                    M.read (|
                                      M.match_operator (|
                                        M.alloc (|
                                          M.call_closure (|
                                            M.get_trait_method (|
                                              "core::ops::try_trait::Try",
                                              Ty.apply
                                                (Ty.path "core::result::Result")
                                                [
                                                  Ty.path
                                                    "spl_pod::optional_keys::OptionalNonZeroElGamalPubkey";
                                                  Ty.path
                                                    "solana_program::program_error::ProgramError"
                                                ],
                                              [],
                                              "branch",
                                              []
                                            |),
                                            [
                                              M.call_closure (|
                                                M.get_trait_method (|
                                                  "core::convert::TryInto",
                                                  Ty.apply
                                                    (Ty.path "core::option::Option")
                                                    [
                                                      Ty.path
                                                        "solana_zk_token_sdk::zk_token_elgamal::pod::elgamal::ElGamalPubkey"
                                                    ],
                                                  [
                                                    Ty.path
                                                      "spl_pod::optional_keys::OptionalNonZeroElGamalPubkey"
                                                  ],
                                                  "try_into",
                                                  []
                                                |),
                                                [ M.read (| auditor_elgamal_pubkey |) ]
                                              |)
                                            ]
                                          |)
                                        |),
                                        [
                                          fun γ =>
                                            ltac:(M.monadic
                                              (let γ0_0 :=
                                                M.SubPointer.get_struct_tuple_field (|
                                                  γ,
                                                  "core::ops::control_flow::ControlFlow::Break",
                                                  0
                                                |) in
                                              let residual := M.copy (| γ0_0 |) in
                                              M.alloc (|
                                                M.never_to_any (|
                                                  M.read (|
                                                    M.return_ (|
                                                      M.call_closure (|
                                                        M.get_trait_method (|
                                                          "core::ops::try_trait::FromResidual",
                                                          Ty.apply
                                                            (Ty.path "core::result::Result")
                                                            [
                                                              Ty.path
                                                                "solana_program::instruction::Instruction";
                                                              Ty.path
                                                                "solana_program::program_error::ProgramError"
                                                            ],
                                                          [
                                                            Ty.apply
                                                              (Ty.path "core::result::Result")
                                                              [
                                                                Ty.path "core::convert::Infallible";
                                                                Ty.path
                                                                  "solana_program::program_error::ProgramError"
                                                              ]
                                                          ],
                                                          "from_residual",
                                                          []
                                                        |),
                                                        [ M.read (| residual |) ]
                                                      |)
                                                    |)
                                                  |)
                                                |)
                                              |)));
                                          fun γ =>
                                            ltac:(M.monadic
                                              (let γ0_0 :=
                                                M.SubPointer.get_struct_tuple_field (|
                                                  γ,
                                                  "core::ops::control_flow::ControlFlow::Continue",
                                                  0
                                                |) in
                                              let val := M.copy (| γ0_0 |) in
                                              val))
                                        ]
                                      |)
                                    |))
                                ]
                            |)
                          ]
                        |)
                      ]
                  |)
                |)))
            |)))
        | _, _ => M.impossible
        end.
      
      (*
      pub fn inner_configure_account(
          token_program_id: &Pubkey,
          token_account: &Pubkey,
          mint: &Pubkey,
          decryptable_zero_balance: AeCiphertext,
          maximum_pending_balance_credit_counter: u64,
          authority: &Pubkey,
          multisig_signers: &[&Pubkey],
          proof_data_location: ProofLocation<PubkeyValidityData>,
      ) -> Result<Instruction, ProgramError> {
          check_program_account(token_program_id)?;
      
          let mut accounts = vec![
              AccountMeta::new( *token_account, false),
              AccountMeta::new_readonly( *mint, false),
          ];
      
          let proof_instruction_offset = match proof_data_location {
              ProofLocation::InstructionOffset(proof_instruction_offset, _) => {
                  accounts.push(AccountMeta::new_readonly(sysvar::instructions::id(), false));
                  proof_instruction_offset.into()
              }
              ProofLocation::ContextStateAccount(context_state_account) => {
                  accounts.push(AccountMeta::new_readonly( *context_state_account, false));
                  0
              }
          };
      
          accounts.push(AccountMeta::new_readonly(
              *authority,
              multisig_signers.is_empty(),
          ));
      
          for multisig_signer in multisig_signers.iter() {
              accounts.push(AccountMeta::new_readonly( **multisig_signer, true));
          }
      
          Ok(encode_instruction(
              token_program_id,
              accounts,
              TokenInstruction::ConfidentialTransferExtension,
              ConfidentialTransferInstruction::ConfigureAccount,
              &ConfigureAccountInstructionData {
                  decryptable_zero_balance: decryptable_zero_balance.into(),
                  maximum_pending_balance_credit_counter: maximum_pending_balance_credit_counter.into(),
                  proof_instruction_offset,
              },
          ))
      }
      *)
      Definition inner_configure_account (τ : list Ty.t) (α : list Value.t) : M :=
        match τ, α with
        | [],
            [
              token_program_id;
              token_account;
              mint;
              decryptable_zero_balance;
              maximum_pending_balance_credit_counter;
              authority;
              multisig_signers;
              proof_data_location
            ] =>
          ltac:(M.monadic
            (let token_program_id := M.alloc (| token_program_id |) in
            let token_account := M.alloc (| token_account |) in
            let mint := M.alloc (| mint |) in
            let decryptable_zero_balance := M.alloc (| decryptable_zero_balance |) in
            let maximum_pending_balance_credit_counter :=
              M.alloc (| maximum_pending_balance_credit_counter |) in
            let authority := M.alloc (| authority |) in
            let multisig_signers := M.alloc (| multisig_signers |) in
            let proof_data_location := M.alloc (| proof_data_location |) in
            M.catch_return (|
              ltac:(M.monadic
                (M.read (|
                  let _ :=
                    M.match_operator (|
                      M.alloc (|
                        M.call_closure (|
                          M.get_trait_method (|
                            "core::ops::try_trait::Try",
                            Ty.apply
                              (Ty.path "core::result::Result")
                              [ Ty.tuple []; Ty.path "solana_program::program_error::ProgramError"
                              ],
                            [],
                            "branch",
                            []
                          |),
                          [
                            M.call_closure (|
                              M.get_function (| "spl_token_2022::check_program_account", [] |),
                              [ M.read (| token_program_id |) ]
                            |)
                          ]
                        |)
                      |),
                      [
                        fun γ =>
                          ltac:(M.monadic
                            (let γ0_0 :=
                              M.SubPointer.get_struct_tuple_field (|
                                γ,
                                "core::ops::control_flow::ControlFlow::Break",
                                0
                              |) in
                            let residual := M.copy (| γ0_0 |) in
                            M.alloc (|
                              M.never_to_any (|
                                M.read (|
                                  M.return_ (|
                                    M.call_closure (|
                                      M.get_trait_method (|
                                        "core::ops::try_trait::FromResidual",
                                        Ty.apply
                                          (Ty.path "core::result::Result")
                                          [
                                            Ty.path "solana_program::instruction::Instruction";
                                            Ty.path "solana_program::program_error::ProgramError"
                                          ],
                                        [
                                          Ty.apply
                                            (Ty.path "core::result::Result")
                                            [
                                              Ty.path "core::convert::Infallible";
                                              Ty.path "solana_program::program_error::ProgramError"
                                            ]
                                        ],
                                        "from_residual",
                                        []
                                      |),
                                      [ M.read (| residual |) ]
                                    |)
                                  |)
                                |)
                              |)
                            |)));
                        fun γ =>
                          ltac:(M.monadic
                            (let γ0_0 :=
                              M.SubPointer.get_struct_tuple_field (|
                                γ,
                                "core::ops::control_flow::ControlFlow::Continue",
                                0
                              |) in
                            let val := M.copy (| γ0_0 |) in
                            val))
                      ]
                    |) in
                  let accounts :=
                    M.alloc (|
                      M.call_closure (|
                        M.get_associated_function (|
                          Ty.apply
                            (Ty.path "slice")
                            [ Ty.path "solana_program::instruction::AccountMeta" ],
                          "into_vec",
                          [ Ty.path "alloc::alloc::Global" ]
                        |),
                        [
                          (* Unsize *)
                          M.pointer_coercion
                            (M.read (|
                              M.call_closure (|
                                M.get_associated_function (|
                                  Ty.apply
                                    (Ty.path "alloc::boxed::Box")
                                    [
                                      Ty.apply
                                        (Ty.path "array")
                                        [ Ty.path "solana_program::instruction::AccountMeta" ];
                                      Ty.path "alloc::alloc::Global"
                                    ],
                                  "new",
                                  []
                                |),
                                [
                                  M.alloc (|
                                    Value.Array
                                      [
                                        M.call_closure (|
                                          M.get_associated_function (|
                                            Ty.path "solana_program::instruction::AccountMeta",
                                            "new",
                                            []
                                          |),
                                          [
                                            M.read (| M.read (| token_account |) |);
                                            Value.Bool false
                                          ]
                                        |);
                                        M.call_closure (|
                                          M.get_associated_function (|
                                            Ty.path "solana_program::instruction::AccountMeta",
                                            "new_readonly",
                                            []
                                          |),
                                          [ M.read (| M.read (| mint |) |); Value.Bool false ]
                                        |)
                                      ]
                                  |)
                                ]
                              |)
                            |))
                        ]
                      |)
                    |) in
                  let proof_instruction_offset :=
                    M.copy (|
                      M.match_operator (|
                        proof_data_location,
                        [
                          fun γ =>
                            ltac:(M.monadic
                              (let γ0_0 :=
                                M.SubPointer.get_struct_tuple_field (|
                                  γ,
                                  "spl_token_2022::proof::ProofLocation::InstructionOffset",
                                  0
                                |) in
                              let γ0_1 :=
                                M.SubPointer.get_struct_tuple_field (|
                                  γ,
                                  "spl_token_2022::proof::ProofLocation::InstructionOffset",
                                  1
                                |) in
                              let proof_instruction_offset := M.copy (| γ0_0 |) in
                              let _ :=
                                M.alloc (|
                                  M.call_closure (|
                                    M.get_associated_function (|
                                      Ty.apply
                                        (Ty.path "alloc::vec::Vec")
                                        [
                                          Ty.path "solana_program::instruction::AccountMeta";
                                          Ty.path "alloc::alloc::Global"
                                        ],
                                      "push",
                                      []
                                    |),
                                    [
                                      accounts;
                                      M.call_closure (|
                                        M.get_associated_function (|
                                          Ty.path "solana_program::instruction::AccountMeta",
                                          "new_readonly",
                                          []
                                        |),
                                        [
                                          M.call_closure (|
                                            M.get_function (|
                                              "solana_program::sysvar::instructions::id",
                                              []
                                            |),
                                            []
                                          |);
                                          Value.Bool false
                                        ]
                                      |)
                                    ]
                                  |)
                                |) in
                              M.alloc (|
                                M.call_closure (|
                                  M.get_trait_method (|
                                    "core::convert::Into",
                                    Ty.path "core::num::nonzero::NonZeroI8",
                                    [ Ty.path "i8" ],
                                    "into",
                                    []
                                  |),
                                  [ M.read (| proof_instruction_offset |) ]
                                |)
                              |)));
                          fun γ =>
                            ltac:(M.monadic
                              (let γ0_0 :=
                                M.SubPointer.get_struct_tuple_field (|
                                  γ,
                                  "spl_token_2022::proof::ProofLocation::ContextStateAccount",
                                  0
                                |) in
                              let context_state_account := M.copy (| γ0_0 |) in
                              let _ :=
                                M.alloc (|
                                  M.call_closure (|
                                    M.get_associated_function (|
                                      Ty.apply
                                        (Ty.path "alloc::vec::Vec")
                                        [
                                          Ty.path "solana_program::instruction::AccountMeta";
                                          Ty.path "alloc::alloc::Global"
                                        ],
                                      "push",
                                      []
                                    |),
                                    [
                                      accounts;
                                      M.call_closure (|
                                        M.get_associated_function (|
                                          Ty.path "solana_program::instruction::AccountMeta",
                                          "new_readonly",
                                          []
                                        |),
                                        [
                                          M.read (| M.read (| context_state_account |) |);
                                          Value.Bool false
                                        ]
                                      |)
                                    ]
                                  |)
                                |) in
                              M.alloc (| Value.Integer 0 |)))
                        ]
                      |)
                    |) in
                  let _ :=
                    M.alloc (|
                      M.call_closure (|
                        M.get_associated_function (|
                          Ty.apply
                            (Ty.path "alloc::vec::Vec")
                            [
                              Ty.path "solana_program::instruction::AccountMeta";
                              Ty.path "alloc::alloc::Global"
                            ],
                          "push",
                          []
                        |),
                        [
                          accounts;
                          M.call_closure (|
                            M.get_associated_function (|
                              Ty.path "solana_program::instruction::AccountMeta",
                              "new_readonly",
                              []
                            |),
                            [
                              M.read (| M.read (| authority |) |);
                              M.call_closure (|
                                M.get_associated_function (|
                                  Ty.apply
                                    (Ty.path "slice")
                                    [
                                      Ty.apply
                                        (Ty.path "&")
                                        [ Ty.path "solana_program::pubkey::Pubkey" ]
                                    ],
                                  "is_empty",
                                  []
                                |),
                                [ M.read (| multisig_signers |) ]
                              |)
                            ]
                          |)
                        ]
                      |)
                    |) in
                  let _ :=
                    M.use
                      (M.match_operator (|
                        M.alloc (|
                          M.call_closure (|
                            M.get_trait_method (|
                              "core::iter::traits::collect::IntoIterator",
                              Ty.apply
                                (Ty.path "core::slice::iter::Iter")
                                [
                                  Ty.apply
                                    (Ty.path "&")
                                    [ Ty.path "solana_program::pubkey::Pubkey" ]
                                ],
                              [],
                              "into_iter",
                              []
                            |),
                            [
                              M.call_closure (|
                                M.get_associated_function (|
                                  Ty.apply
                                    (Ty.path "slice")
                                    [
                                      Ty.apply
                                        (Ty.path "&")
                                        [ Ty.path "solana_program::pubkey::Pubkey" ]
                                    ],
                                  "iter",
                                  []
                                |),
                                [ M.read (| multisig_signers |) ]
                              |)
                            ]
                          |)
                        |),
                        [
                          fun γ =>
                            ltac:(M.monadic
                              (let iter := M.copy (| γ |) in
                              M.loop (|
                                ltac:(M.monadic
                                  (let _ :=
                                    M.match_operator (|
                                      M.alloc (|
                                        M.call_closure (|
                                          M.get_trait_method (|
                                            "core::iter::traits::iterator::Iterator",
                                            Ty.apply
                                              (Ty.path "core::slice::iter::Iter")
                                              [
                                                Ty.apply
                                                  (Ty.path "&")
                                                  [ Ty.path "solana_program::pubkey::Pubkey" ]
                                              ],
                                            [],
                                            "next",
                                            []
                                          |),
                                          [ iter ]
                                        |)
                                      |),
                                      [
                                        fun γ =>
                                          ltac:(M.monadic
                                            (M.alloc (|
                                              M.never_to_any (| M.read (| M.break (||) |) |)
                                            |)));
                                        fun γ =>
                                          ltac:(M.monadic
                                            (let γ0_0 :=
                                              M.SubPointer.get_struct_tuple_field (|
                                                γ,
                                                "core::option::Option::Some",
                                                0
                                              |) in
                                            let multisig_signer := M.copy (| γ0_0 |) in
                                            let _ :=
                                              M.alloc (|
                                                M.call_closure (|
                                                  M.get_associated_function (|
                                                    Ty.apply
                                                      (Ty.path "alloc::vec::Vec")
                                                      [
                                                        Ty.path
                                                          "solana_program::instruction::AccountMeta";
                                                        Ty.path "alloc::alloc::Global"
                                                      ],
                                                    "push",
                                                    []
                                                  |),
                                                  [
                                                    accounts;
                                                    M.call_closure (|
                                                      M.get_associated_function (|
                                                        Ty.path
                                                          "solana_program::instruction::AccountMeta",
                                                        "new_readonly",
                                                        []
                                                      |),
                                                      [
                                                        M.read (|
                                                          M.read (| M.read (| multisig_signer |) |)
                                                        |);
                                                        Value.Bool true
                                                      ]
                                                    |)
                                                  ]
                                                |)
                                              |) in
                                            M.alloc (| Value.Tuple [] |)))
                                      ]
                                    |) in
                                  M.alloc (| Value.Tuple [] |)))
                              |)))
                        ]
                      |)) in
                  M.alloc (|
                    Value.StructTuple
                      "core::result::Result::Ok"
                      [
                        M.call_closure (|
                          M.get_function (|
                            "spl_token_2022::instruction::encode_instruction",
                            [
                              Ty.path
                                "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction";
                              Ty.path
                                "spl_token_2022::extension::confidential_transfer::instruction::ConfigureAccountInstructionData"
                            ]
                          |),
                          [
                            M.read (| token_program_id |);
                            M.read (| accounts |);
                            Value.StructTuple
                              "spl_token_2022::instruction::TokenInstruction::ConfidentialTransferExtension"
                              [];
                            Value.StructTuple
                              "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction::ConfigureAccount"
                              [];
                            M.alloc (|
                              Value.StructRecord
                                "spl_token_2022::extension::confidential_transfer::instruction::ConfigureAccountInstructionData"
                                [
                                  ("decryptable_zero_balance",
                                    M.call_closure (|
                                      M.get_trait_method (|
                                        "core::convert::Into",
                                        Ty.path
                                          "solana_zk_token_sdk::encryption::auth_encryption::AeCiphertext",
                                        [
                                          Ty.path
                                            "solana_zk_token_sdk::zk_token_elgamal::pod::auth_encryption::AeCiphertext"
                                        ],
                                        "into",
                                        []
                                      |),
                                      [ M.read (| decryptable_zero_balance |) ]
                                    |));
                                  ("maximum_pending_balance_credit_counter",
                                    M.call_closure (|
                                      M.get_trait_method (|
                                        "core::convert::Into",
                                        Ty.path "u64",
                                        [ Ty.path "spl_pod::primitives::PodU64" ],
                                        "into",
                                        []
                                      |),
                                      [ M.read (| maximum_pending_balance_credit_counter |) ]
                                    |));
                                  ("proof_instruction_offset",
                                    M.read (| proof_instruction_offset |))
                                ]
                            |)
                          ]
                        |)
                      ]
                  |)
                |)))
            |)))
        | _, _ => M.impossible
        end.
      
      (*
      pub fn configure_account(
          token_program_id: &Pubkey,
          token_account: &Pubkey,
          mint: &Pubkey,
          decryptable_zero_balance: AeCiphertext,
          maximum_pending_balance_credit_counter: u64,
          authority: &Pubkey,
          multisig_signers: &[&Pubkey],
          proof_data_location: ProofLocation<PubkeyValidityData>,
      ) -> Result<Vec<Instruction>, ProgramError> {
          let mut instructions = vec![inner_configure_account(
              token_program_id,
              token_account,
              mint,
              decryptable_zero_balance,
              maximum_pending_balance_credit_counter,
              authority,
              multisig_signers,
              proof_data_location,
          )?];
      
          if let ProofLocation::InstructionOffset(proof_instruction_offset, proof_data) =
              proof_data_location
          {
              // This constructor appends the proof instruction right after the
              // `ConfigureAccount` instruction. This means that the proof instruction
              // offset must be always be 1. To use an arbitrary proof instruction
              // offset, use the `inner_configure_account` constructor.
              let proof_instruction_offset: i8 = proof_instruction_offset.into();
              if proof_instruction_offset != 1 {
                  return Err(TokenError::InvalidProofInstructionOffset.into());
              }
              instructions.push(verify_pubkey_validity(None, proof_data));
          };
      
          Ok(instructions)
      }
      *)
      Definition configure_account (τ : list Ty.t) (α : list Value.t) : M :=
        match τ, α with
        | [],
            [
              token_program_id;
              token_account;
              mint;
              decryptable_zero_balance;
              maximum_pending_balance_credit_counter;
              authority;
              multisig_signers;
              proof_data_location
            ] =>
          ltac:(M.monadic
            (let token_program_id := M.alloc (| token_program_id |) in
            let token_account := M.alloc (| token_account |) in
            let mint := M.alloc (| mint |) in
            let decryptable_zero_balance := M.alloc (| decryptable_zero_balance |) in
            let maximum_pending_balance_credit_counter :=
              M.alloc (| maximum_pending_balance_credit_counter |) in
            let authority := M.alloc (| authority |) in
            let multisig_signers := M.alloc (| multisig_signers |) in
            let proof_data_location := M.alloc (| proof_data_location |) in
            M.catch_return (|
              ltac:(M.monadic
                (M.read (|
                  let instructions :=
                    M.alloc (|
                      M.call_closure (|
                        M.get_associated_function (|
                          Ty.apply
                            (Ty.path "slice")
                            [ Ty.path "solana_program::instruction::Instruction" ],
                          "into_vec",
                          [ Ty.path "alloc::alloc::Global" ]
                        |),
                        [
                          (* Unsize *)
                          M.pointer_coercion
                            (M.read (|
                              M.call_closure (|
                                M.get_associated_function (|
                                  Ty.apply
                                    (Ty.path "alloc::boxed::Box")
                                    [
                                      Ty.apply
                                        (Ty.path "array")
                                        [ Ty.path "solana_program::instruction::Instruction" ];
                                      Ty.path "alloc::alloc::Global"
                                    ],
                                  "new",
                                  []
                                |),
                                [
                                  M.alloc (|
                                    Value.Array
                                      [
                                        M.read (|
                                          M.match_operator (|
                                            M.alloc (|
                                              M.call_closure (|
                                                M.get_trait_method (|
                                                  "core::ops::try_trait::Try",
                                                  Ty.apply
                                                    (Ty.path "core::result::Result")
                                                    [
                                                      Ty.path
                                                        "solana_program::instruction::Instruction";
                                                      Ty.path
                                                        "solana_program::program_error::ProgramError"
                                                    ],
                                                  [],
                                                  "branch",
                                                  []
                                                |),
                                                [
                                                  M.call_closure (|
                                                    M.get_function (|
                                                      "spl_token_2022::extension::confidential_transfer::instruction::inner_configure_account",
                                                      []
                                                    |),
                                                    [
                                                      M.read (| token_program_id |);
                                                      M.read (| token_account |);
                                                      M.read (| mint |);
                                                      M.read (| decryptable_zero_balance |);
                                                      M.read (|
                                                        maximum_pending_balance_credit_counter
                                                      |);
                                                      M.read (| authority |);
                                                      M.read (| multisig_signers |);
                                                      M.read (| proof_data_location |)
                                                    ]
                                                  |)
                                                ]
                                              |)
                                            |),
                                            [
                                              fun γ =>
                                                ltac:(M.monadic
                                                  (let γ0_0 :=
                                                    M.SubPointer.get_struct_tuple_field (|
                                                      γ,
                                                      "core::ops::control_flow::ControlFlow::Break",
                                                      0
                                                    |) in
                                                  let residual := M.copy (| γ0_0 |) in
                                                  M.alloc (|
                                                    M.never_to_any (|
                                                      M.read (|
                                                        M.return_ (|
                                                          M.call_closure (|
                                                            M.get_trait_method (|
                                                              "core::ops::try_trait::FromResidual",
                                                              Ty.apply
                                                                (Ty.path "core::result::Result")
                                                                [
                                                                  Ty.apply
                                                                    (Ty.path "alloc::vec::Vec")
                                                                    [
                                                                      Ty.path
                                                                        "solana_program::instruction::Instruction";
                                                                      Ty.path "alloc::alloc::Global"
                                                                    ];
                                                                  Ty.path
                                                                    "solana_program::program_error::ProgramError"
                                                                ],
                                                              [
                                                                Ty.apply
                                                                  (Ty.path "core::result::Result")
                                                                  [
                                                                    Ty.path
                                                                      "core::convert::Infallible";
                                                                    Ty.path
                                                                      "solana_program::program_error::ProgramError"
                                                                  ]
                                                              ],
                                                              "from_residual",
                                                              []
                                                            |),
                                                            [ M.read (| residual |) ]
                                                          |)
                                                        |)
                                                      |)
                                                    |)
                                                  |)));
                                              fun γ =>
                                                ltac:(M.monadic
                                                  (let γ0_0 :=
                                                    M.SubPointer.get_struct_tuple_field (|
                                                      γ,
                                                      "core::ops::control_flow::ControlFlow::Continue",
                                                      0
                                                    |) in
                                                  let val := M.copy (| γ0_0 |) in
                                                  val))
                                            ]
                                          |)
                                        |)
                                      ]
                                  |)
                                ]
                              |)
                            |))
                        ]
                      |)
                    |) in
                  let _ :=
                    M.match_operator (|
                      M.alloc (| Value.Tuple [] |),
                      [
                        fun γ =>
                          ltac:(M.monadic
                            (let γ := proof_data_location in
                            let γ0_0 :=
                              M.SubPointer.get_struct_tuple_field (|
                                γ,
                                "spl_token_2022::proof::ProofLocation::InstructionOffset",
                                0
                              |) in
                            let γ0_1 :=
                              M.SubPointer.get_struct_tuple_field (|
                                γ,
                                "spl_token_2022::proof::ProofLocation::InstructionOffset",
                                1
                              |) in
                            let proof_instruction_offset := M.copy (| γ0_0 |) in
                            let proof_data := M.copy (| γ0_1 |) in
                            let proof_instruction_offset :=
                              M.alloc (|
                                M.call_closure (|
                                  M.get_trait_method (|
                                    "core::convert::Into",
                                    Ty.path "core::num::nonzero::NonZeroI8",
                                    [ Ty.path "i8" ],
                                    "into",
                                    []
                                  |),
                                  [ M.read (| proof_instruction_offset |) ]
                                |)
                              |) in
                            let _ :=
                              M.match_operator (|
                                M.alloc (| Value.Tuple [] |),
                                [
                                  fun γ =>
                                    ltac:(M.monadic
                                      (let γ :=
                                        M.use
                                          (M.alloc (|
                                            BinOp.Pure.ne
                                              (M.read (| proof_instruction_offset |))
                                              (Value.Integer 1)
                                          |)) in
                                      let _ :=
                                        M.is_constant_or_break_match (|
                                          M.read (| γ |),
                                          Value.Bool true
                                        |) in
                                      M.alloc (|
                                        M.never_to_any (|
                                          M.read (|
                                            M.return_ (|
                                              Value.StructTuple
                                                "core::result::Result::Err"
                                                [
                                                  M.call_closure (|
                                                    M.get_trait_method (|
                                                      "core::convert::Into",
                                                      Ty.path "spl_token_2022::error::TokenError",
                                                      [
                                                        Ty.path
                                                          "solana_program::program_error::ProgramError"
                                                      ],
                                                      "into",
                                                      []
                                                    |),
                                                    [
                                                      Value.StructTuple
                                                        "spl_token_2022::error::TokenError::InvalidProofInstructionOffset"
                                                        []
                                                    ]
                                                  |)
                                                ]
                                            |)
                                          |)
                                        |)
                                      |)));
                                  fun γ => ltac:(M.monadic (M.alloc (| Value.Tuple [] |)))
                                ]
                              |) in
                            let _ :=
                              M.alloc (|
                                M.call_closure (|
                                  M.get_associated_function (|
                                    Ty.apply
                                      (Ty.path "alloc::vec::Vec")
                                      [
                                        Ty.path "solana_program::instruction::Instruction";
                                        Ty.path "alloc::alloc::Global"
                                      ],
                                    "push",
                                    []
                                  |),
                                  [
                                    instructions;
                                    M.call_closure (|
                                      M.get_function (|
                                        "solana_zk_token_sdk::zk_token_proof_instruction::verify_pubkey_validity",
                                        []
                                      |),
                                      [
                                        Value.StructTuple "core::option::Option::None" [];
                                        M.read (| proof_data |)
                                      ]
                                    |)
                                  ]
                                |)
                              |) in
                            M.alloc (| Value.Tuple [] |)));
                        fun γ => ltac:(M.monadic (M.alloc (| Value.Tuple [] |)))
                      ]
                    |) in
                  M.alloc (|
                    Value.StructTuple "core::result::Result::Ok" [ M.read (| instructions |) ]
                  |)
                |)))
            |)))
        | _, _ => M.impossible
        end.
      
      (*
      pub fn approve_account(
          token_program_id: &Pubkey,
          account_to_approve: &Pubkey,
          mint: &Pubkey,
          authority: &Pubkey,
          multisig_signers: &[&Pubkey],
      ) -> Result<Instruction, ProgramError> {
          check_program_account(token_program_id)?;
          let mut accounts = vec![
              AccountMeta::new( *account_to_approve, false),
              AccountMeta::new_readonly( *mint, false),
              AccountMeta::new_readonly( *authority, multisig_signers.is_empty()),
          ];
          for multisig_signer in multisig_signers.iter() {
              accounts.push(AccountMeta::new_readonly( **multisig_signer, true));
          }
          Ok(encode_instruction(
              token_program_id,
              accounts,
              TokenInstruction::ConfidentialTransferExtension,
              ConfidentialTransferInstruction::ApproveAccount,
              &(),
          ))
      }
      *)
      Definition approve_account (τ : list Ty.t) (α : list Value.t) : M :=
        match τ, α with
        | [], [ token_program_id; account_to_approve; mint; authority; multisig_signers ] =>
          ltac:(M.monadic
            (let token_program_id := M.alloc (| token_program_id |) in
            let account_to_approve := M.alloc (| account_to_approve |) in
            let mint := M.alloc (| mint |) in
            let authority := M.alloc (| authority |) in
            let multisig_signers := M.alloc (| multisig_signers |) in
            M.catch_return (|
              ltac:(M.monadic
                (M.read (|
                  let _ :=
                    M.match_operator (|
                      M.alloc (|
                        M.call_closure (|
                          M.get_trait_method (|
                            "core::ops::try_trait::Try",
                            Ty.apply
                              (Ty.path "core::result::Result")
                              [ Ty.tuple []; Ty.path "solana_program::program_error::ProgramError"
                              ],
                            [],
                            "branch",
                            []
                          |),
                          [
                            M.call_closure (|
                              M.get_function (| "spl_token_2022::check_program_account", [] |),
                              [ M.read (| token_program_id |) ]
                            |)
                          ]
                        |)
                      |),
                      [
                        fun γ =>
                          ltac:(M.monadic
                            (let γ0_0 :=
                              M.SubPointer.get_struct_tuple_field (|
                                γ,
                                "core::ops::control_flow::ControlFlow::Break",
                                0
                              |) in
                            let residual := M.copy (| γ0_0 |) in
                            M.alloc (|
                              M.never_to_any (|
                                M.read (|
                                  M.return_ (|
                                    M.call_closure (|
                                      M.get_trait_method (|
                                        "core::ops::try_trait::FromResidual",
                                        Ty.apply
                                          (Ty.path "core::result::Result")
                                          [
                                            Ty.path "solana_program::instruction::Instruction";
                                            Ty.path "solana_program::program_error::ProgramError"
                                          ],
                                        [
                                          Ty.apply
                                            (Ty.path "core::result::Result")
                                            [
                                              Ty.path "core::convert::Infallible";
                                              Ty.path "solana_program::program_error::ProgramError"
                                            ]
                                        ],
                                        "from_residual",
                                        []
                                      |),
                                      [ M.read (| residual |) ]
                                    |)
                                  |)
                                |)
                              |)
                            |)));
                        fun γ =>
                          ltac:(M.monadic
                            (let γ0_0 :=
                              M.SubPointer.get_struct_tuple_field (|
                                γ,
                                "core::ops::control_flow::ControlFlow::Continue",
                                0
                              |) in
                            let val := M.copy (| γ0_0 |) in
                            val))
                      ]
                    |) in
                  let accounts :=
                    M.alloc (|
                      M.call_closure (|
                        M.get_associated_function (|
                          Ty.apply
                            (Ty.path "slice")
                            [ Ty.path "solana_program::instruction::AccountMeta" ],
                          "into_vec",
                          [ Ty.path "alloc::alloc::Global" ]
                        |),
                        [
                          (* Unsize *)
                          M.pointer_coercion
                            (M.read (|
                              M.call_closure (|
                                M.get_associated_function (|
                                  Ty.apply
                                    (Ty.path "alloc::boxed::Box")
                                    [
                                      Ty.apply
                                        (Ty.path "array")
                                        [ Ty.path "solana_program::instruction::AccountMeta" ];
                                      Ty.path "alloc::alloc::Global"
                                    ],
                                  "new",
                                  []
                                |),
                                [
                                  M.alloc (|
                                    Value.Array
                                      [
                                        M.call_closure (|
                                          M.get_associated_function (|
                                            Ty.path "solana_program::instruction::AccountMeta",
                                            "new",
                                            []
                                          |),
                                          [
                                            M.read (| M.read (| account_to_approve |) |);
                                            Value.Bool false
                                          ]
                                        |);
                                        M.call_closure (|
                                          M.get_associated_function (|
                                            Ty.path "solana_program::instruction::AccountMeta",
                                            "new_readonly",
                                            []
                                          |),
                                          [ M.read (| M.read (| mint |) |); Value.Bool false ]
                                        |);
                                        M.call_closure (|
                                          M.get_associated_function (|
                                            Ty.path "solana_program::instruction::AccountMeta",
                                            "new_readonly",
                                            []
                                          |),
                                          [
                                            M.read (| M.read (| authority |) |);
                                            M.call_closure (|
                                              M.get_associated_function (|
                                                Ty.apply
                                                  (Ty.path "slice")
                                                  [
                                                    Ty.apply
                                                      (Ty.path "&")
                                                      [ Ty.path "solana_program::pubkey::Pubkey" ]
                                                  ],
                                                "is_empty",
                                                []
                                              |),
                                              [ M.read (| multisig_signers |) ]
                                            |)
                                          ]
                                        |)
                                      ]
                                  |)
                                ]
                              |)
                            |))
                        ]
                      |)
                    |) in
                  let _ :=
                    M.use
                      (M.match_operator (|
                        M.alloc (|
                          M.call_closure (|
                            M.get_trait_method (|
                              "core::iter::traits::collect::IntoIterator",
                              Ty.apply
                                (Ty.path "core::slice::iter::Iter")
                                [
                                  Ty.apply
                                    (Ty.path "&")
                                    [ Ty.path "solana_program::pubkey::Pubkey" ]
                                ],
                              [],
                              "into_iter",
                              []
                            |),
                            [
                              M.call_closure (|
                                M.get_associated_function (|
                                  Ty.apply
                                    (Ty.path "slice")
                                    [
                                      Ty.apply
                                        (Ty.path "&")
                                        [ Ty.path "solana_program::pubkey::Pubkey" ]
                                    ],
                                  "iter",
                                  []
                                |),
                                [ M.read (| multisig_signers |) ]
                              |)
                            ]
                          |)
                        |),
                        [
                          fun γ =>
                            ltac:(M.monadic
                              (let iter := M.copy (| γ |) in
                              M.loop (|
                                ltac:(M.monadic
                                  (let _ :=
                                    M.match_operator (|
                                      M.alloc (|
                                        M.call_closure (|
                                          M.get_trait_method (|
                                            "core::iter::traits::iterator::Iterator",
                                            Ty.apply
                                              (Ty.path "core::slice::iter::Iter")
                                              [
                                                Ty.apply
                                                  (Ty.path "&")
                                                  [ Ty.path "solana_program::pubkey::Pubkey" ]
                                              ],
                                            [],
                                            "next",
                                            []
                                          |),
                                          [ iter ]
                                        |)
                                      |),
                                      [
                                        fun γ =>
                                          ltac:(M.monadic
                                            (M.alloc (|
                                              M.never_to_any (| M.read (| M.break (||) |) |)
                                            |)));
                                        fun γ =>
                                          ltac:(M.monadic
                                            (let γ0_0 :=
                                              M.SubPointer.get_struct_tuple_field (|
                                                γ,
                                                "core::option::Option::Some",
                                                0
                                              |) in
                                            let multisig_signer := M.copy (| γ0_0 |) in
                                            let _ :=
                                              M.alloc (|
                                                M.call_closure (|
                                                  M.get_associated_function (|
                                                    Ty.apply
                                                      (Ty.path "alloc::vec::Vec")
                                                      [
                                                        Ty.path
                                                          "solana_program::instruction::AccountMeta";
                                                        Ty.path "alloc::alloc::Global"
                                                      ],
                                                    "push",
                                                    []
                                                  |),
                                                  [
                                                    accounts;
                                                    M.call_closure (|
                                                      M.get_associated_function (|
                                                        Ty.path
                                                          "solana_program::instruction::AccountMeta",
                                                        "new_readonly",
                                                        []
                                                      |),
                                                      [
                                                        M.read (|
                                                          M.read (| M.read (| multisig_signer |) |)
                                                        |);
                                                        Value.Bool true
                                                      ]
                                                    |)
                                                  ]
                                                |)
                                              |) in
                                            M.alloc (| Value.Tuple [] |)))
                                      ]
                                    |) in
                                  M.alloc (| Value.Tuple [] |)))
                              |)))
                        ]
                      |)) in
                  M.alloc (|
                    Value.StructTuple
                      "core::result::Result::Ok"
                      [
                        M.call_closure (|
                          M.get_function (|
                            "spl_token_2022::instruction::encode_instruction",
                            [
                              Ty.path
                                "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction";
                              Ty.tuple []
                            ]
                          |),
                          [
                            M.read (| token_program_id |);
                            M.read (| accounts |);
                            Value.StructTuple
                              "spl_token_2022::instruction::TokenInstruction::ConfidentialTransferExtension"
                              [];
                            Value.StructTuple
                              "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction::ApproveAccount"
                              [];
                            M.alloc (| Value.Tuple [] |)
                          ]
                        |)
                      ]
                  |)
                |)))
            |)))
        | _, _ => M.impossible
        end.
      
      (*
      pub fn inner_empty_account(
          token_program_id: &Pubkey,
          token_account: &Pubkey,
          authority: &Pubkey,
          multisig_signers: &[&Pubkey],
          proof_data_location: ProofLocation<ZeroBalanceProofData>,
      ) -> Result<Instruction, ProgramError> {
          check_program_account(token_program_id)?;
          let mut accounts = vec![AccountMeta::new( *token_account, false)];
      
          let proof_instruction_offset = match proof_data_location {
              ProofLocation::InstructionOffset(proof_instruction_offset, _) => {
                  accounts.push(AccountMeta::new_readonly(sysvar::instructions::id(), false));
                  proof_instruction_offset.into()
              }
              ProofLocation::ContextStateAccount(context_state_account) => {
                  accounts.push(AccountMeta::new_readonly( *context_state_account, false));
                  0
              }
          };
      
          accounts.push(AccountMeta::new_readonly(
              *authority,
              multisig_signers.is_empty(),
          ));
      
          for multisig_signer in multisig_signers.iter() {
              accounts.push(AccountMeta::new_readonly( **multisig_signer, true));
          }
      
          Ok(encode_instruction(
              token_program_id,
              accounts,
              TokenInstruction::ConfidentialTransferExtension,
              ConfidentialTransferInstruction::EmptyAccount,
              &EmptyAccountInstructionData {
                  proof_instruction_offset,
              },
          ))
      }
      *)
      Definition inner_empty_account (τ : list Ty.t) (α : list Value.t) : M :=
        match τ, α with
        | [],
            [ token_program_id; token_account; authority; multisig_signers; proof_data_location ] =>
          ltac:(M.monadic
            (let token_program_id := M.alloc (| token_program_id |) in
            let token_account := M.alloc (| token_account |) in
            let authority := M.alloc (| authority |) in
            let multisig_signers := M.alloc (| multisig_signers |) in
            let proof_data_location := M.alloc (| proof_data_location |) in
            M.catch_return (|
              ltac:(M.monadic
                (M.read (|
                  let _ :=
                    M.match_operator (|
                      M.alloc (|
                        M.call_closure (|
                          M.get_trait_method (|
                            "core::ops::try_trait::Try",
                            Ty.apply
                              (Ty.path "core::result::Result")
                              [ Ty.tuple []; Ty.path "solana_program::program_error::ProgramError"
                              ],
                            [],
                            "branch",
                            []
                          |),
                          [
                            M.call_closure (|
                              M.get_function (| "spl_token_2022::check_program_account", [] |),
                              [ M.read (| token_program_id |) ]
                            |)
                          ]
                        |)
                      |),
                      [
                        fun γ =>
                          ltac:(M.monadic
                            (let γ0_0 :=
                              M.SubPointer.get_struct_tuple_field (|
                                γ,
                                "core::ops::control_flow::ControlFlow::Break",
                                0
                              |) in
                            let residual := M.copy (| γ0_0 |) in
                            M.alloc (|
                              M.never_to_any (|
                                M.read (|
                                  M.return_ (|
                                    M.call_closure (|
                                      M.get_trait_method (|
                                        "core::ops::try_trait::FromResidual",
                                        Ty.apply
                                          (Ty.path "core::result::Result")
                                          [
                                            Ty.path "solana_program::instruction::Instruction";
                                            Ty.path "solana_program::program_error::ProgramError"
                                          ],
                                        [
                                          Ty.apply
                                            (Ty.path "core::result::Result")
                                            [
                                              Ty.path "core::convert::Infallible";
                                              Ty.path "solana_program::program_error::ProgramError"
                                            ]
                                        ],
                                        "from_residual",
                                        []
                                      |),
                                      [ M.read (| residual |) ]
                                    |)
                                  |)
                                |)
                              |)
                            |)));
                        fun γ =>
                          ltac:(M.monadic
                            (let γ0_0 :=
                              M.SubPointer.get_struct_tuple_field (|
                                γ,
                                "core::ops::control_flow::ControlFlow::Continue",
                                0
                              |) in
                            let val := M.copy (| γ0_0 |) in
                            val))
                      ]
                    |) in
                  let accounts :=
                    M.alloc (|
                      M.call_closure (|
                        M.get_associated_function (|
                          Ty.apply
                            (Ty.path "slice")
                            [ Ty.path "solana_program::instruction::AccountMeta" ],
                          "into_vec",
                          [ Ty.path "alloc::alloc::Global" ]
                        |),
                        [
                          (* Unsize *)
                          M.pointer_coercion
                            (M.read (|
                              M.call_closure (|
                                M.get_associated_function (|
                                  Ty.apply
                                    (Ty.path "alloc::boxed::Box")
                                    [
                                      Ty.apply
                                        (Ty.path "array")
                                        [ Ty.path "solana_program::instruction::AccountMeta" ];
                                      Ty.path "alloc::alloc::Global"
                                    ],
                                  "new",
                                  []
                                |),
                                [
                                  M.alloc (|
                                    Value.Array
                                      [
                                        M.call_closure (|
                                          M.get_associated_function (|
                                            Ty.path "solana_program::instruction::AccountMeta",
                                            "new",
                                            []
                                          |),
                                          [
                                            M.read (| M.read (| token_account |) |);
                                            Value.Bool false
                                          ]
                                        |)
                                      ]
                                  |)
                                ]
                              |)
                            |))
                        ]
                      |)
                    |) in
                  let proof_instruction_offset :=
                    M.copy (|
                      M.match_operator (|
                        proof_data_location,
                        [
                          fun γ =>
                            ltac:(M.monadic
                              (let γ0_0 :=
                                M.SubPointer.get_struct_tuple_field (|
                                  γ,
                                  "spl_token_2022::proof::ProofLocation::InstructionOffset",
                                  0
                                |) in
                              let γ0_1 :=
                                M.SubPointer.get_struct_tuple_field (|
                                  γ,
                                  "spl_token_2022::proof::ProofLocation::InstructionOffset",
                                  1
                                |) in
                              let proof_instruction_offset := M.copy (| γ0_0 |) in
                              let _ :=
                                M.alloc (|
                                  M.call_closure (|
                                    M.get_associated_function (|
                                      Ty.apply
                                        (Ty.path "alloc::vec::Vec")
                                        [
                                          Ty.path "solana_program::instruction::AccountMeta";
                                          Ty.path "alloc::alloc::Global"
                                        ],
                                      "push",
                                      []
                                    |),
                                    [
                                      accounts;
                                      M.call_closure (|
                                        M.get_associated_function (|
                                          Ty.path "solana_program::instruction::AccountMeta",
                                          "new_readonly",
                                          []
                                        |),
                                        [
                                          M.call_closure (|
                                            M.get_function (|
                                              "solana_program::sysvar::instructions::id",
                                              []
                                            |),
                                            []
                                          |);
                                          Value.Bool false
                                        ]
                                      |)
                                    ]
                                  |)
                                |) in
                              M.alloc (|
                                M.call_closure (|
                                  M.get_trait_method (|
                                    "core::convert::Into",
                                    Ty.path "core::num::nonzero::NonZeroI8",
                                    [ Ty.path "i8" ],
                                    "into",
                                    []
                                  |),
                                  [ M.read (| proof_instruction_offset |) ]
                                |)
                              |)));
                          fun γ =>
                            ltac:(M.monadic
                              (let γ0_0 :=
                                M.SubPointer.get_struct_tuple_field (|
                                  γ,
                                  "spl_token_2022::proof::ProofLocation::ContextStateAccount",
                                  0
                                |) in
                              let context_state_account := M.copy (| γ0_0 |) in
                              let _ :=
                                M.alloc (|
                                  M.call_closure (|
                                    M.get_associated_function (|
                                      Ty.apply
                                        (Ty.path "alloc::vec::Vec")
                                        [
                                          Ty.path "solana_program::instruction::AccountMeta";
                                          Ty.path "alloc::alloc::Global"
                                        ],
                                      "push",
                                      []
                                    |),
                                    [
                                      accounts;
                                      M.call_closure (|
                                        M.get_associated_function (|
                                          Ty.path "solana_program::instruction::AccountMeta",
                                          "new_readonly",
                                          []
                                        |),
                                        [
                                          M.read (| M.read (| context_state_account |) |);
                                          Value.Bool false
                                        ]
                                      |)
                                    ]
                                  |)
                                |) in
                              M.alloc (| Value.Integer 0 |)))
                        ]
                      |)
                    |) in
                  let _ :=
                    M.alloc (|
                      M.call_closure (|
                        M.get_associated_function (|
                          Ty.apply
                            (Ty.path "alloc::vec::Vec")
                            [
                              Ty.path "solana_program::instruction::AccountMeta";
                              Ty.path "alloc::alloc::Global"
                            ],
                          "push",
                          []
                        |),
                        [
                          accounts;
                          M.call_closure (|
                            M.get_associated_function (|
                              Ty.path "solana_program::instruction::AccountMeta",
                              "new_readonly",
                              []
                            |),
                            [
                              M.read (| M.read (| authority |) |);
                              M.call_closure (|
                                M.get_associated_function (|
                                  Ty.apply
                                    (Ty.path "slice")
                                    [
                                      Ty.apply
                                        (Ty.path "&")
                                        [ Ty.path "solana_program::pubkey::Pubkey" ]
                                    ],
                                  "is_empty",
                                  []
                                |),
                                [ M.read (| multisig_signers |) ]
                              |)
                            ]
                          |)
                        ]
                      |)
                    |) in
                  let _ :=
                    M.use
                      (M.match_operator (|
                        M.alloc (|
                          M.call_closure (|
                            M.get_trait_method (|
                              "core::iter::traits::collect::IntoIterator",
                              Ty.apply
                                (Ty.path "core::slice::iter::Iter")
                                [
                                  Ty.apply
                                    (Ty.path "&")
                                    [ Ty.path "solana_program::pubkey::Pubkey" ]
                                ],
                              [],
                              "into_iter",
                              []
                            |),
                            [
                              M.call_closure (|
                                M.get_associated_function (|
                                  Ty.apply
                                    (Ty.path "slice")
                                    [
                                      Ty.apply
                                        (Ty.path "&")
                                        [ Ty.path "solana_program::pubkey::Pubkey" ]
                                    ],
                                  "iter",
                                  []
                                |),
                                [ M.read (| multisig_signers |) ]
                              |)
                            ]
                          |)
                        |),
                        [
                          fun γ =>
                            ltac:(M.monadic
                              (let iter := M.copy (| γ |) in
                              M.loop (|
                                ltac:(M.monadic
                                  (let _ :=
                                    M.match_operator (|
                                      M.alloc (|
                                        M.call_closure (|
                                          M.get_trait_method (|
                                            "core::iter::traits::iterator::Iterator",
                                            Ty.apply
                                              (Ty.path "core::slice::iter::Iter")
                                              [
                                                Ty.apply
                                                  (Ty.path "&")
                                                  [ Ty.path "solana_program::pubkey::Pubkey" ]
                                              ],
                                            [],
                                            "next",
                                            []
                                          |),
                                          [ iter ]
                                        |)
                                      |),
                                      [
                                        fun γ =>
                                          ltac:(M.monadic
                                            (M.alloc (|
                                              M.never_to_any (| M.read (| M.break (||) |) |)
                                            |)));
                                        fun γ =>
                                          ltac:(M.monadic
                                            (let γ0_0 :=
                                              M.SubPointer.get_struct_tuple_field (|
                                                γ,
                                                "core::option::Option::Some",
                                                0
                                              |) in
                                            let multisig_signer := M.copy (| γ0_0 |) in
                                            let _ :=
                                              M.alloc (|
                                                M.call_closure (|
                                                  M.get_associated_function (|
                                                    Ty.apply
                                                      (Ty.path "alloc::vec::Vec")
                                                      [
                                                        Ty.path
                                                          "solana_program::instruction::AccountMeta";
                                                        Ty.path "alloc::alloc::Global"
                                                      ],
                                                    "push",
                                                    []
                                                  |),
                                                  [
                                                    accounts;
                                                    M.call_closure (|
                                                      M.get_associated_function (|
                                                        Ty.path
                                                          "solana_program::instruction::AccountMeta",
                                                        "new_readonly",
                                                        []
                                                      |),
                                                      [
                                                        M.read (|
                                                          M.read (| M.read (| multisig_signer |) |)
                                                        |);
                                                        Value.Bool true
                                                      ]
                                                    |)
                                                  ]
                                                |)
                                              |) in
                                            M.alloc (| Value.Tuple [] |)))
                                      ]
                                    |) in
                                  M.alloc (| Value.Tuple [] |)))
                              |)))
                        ]
                      |)) in
                  M.alloc (|
                    Value.StructTuple
                      "core::result::Result::Ok"
                      [
                        M.call_closure (|
                          M.get_function (|
                            "spl_token_2022::instruction::encode_instruction",
                            [
                              Ty.path
                                "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction";
                              Ty.path
                                "spl_token_2022::extension::confidential_transfer::instruction::EmptyAccountInstructionData"
                            ]
                          |),
                          [
                            M.read (| token_program_id |);
                            M.read (| accounts |);
                            Value.StructTuple
                              "spl_token_2022::instruction::TokenInstruction::ConfidentialTransferExtension"
                              [];
                            Value.StructTuple
                              "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction::EmptyAccount"
                              [];
                            M.alloc (|
                              Value.StructRecord
                                "spl_token_2022::extension::confidential_transfer::instruction::EmptyAccountInstructionData"
                                [
                                  ("proof_instruction_offset",
                                    M.read (| proof_instruction_offset |))
                                ]
                            |)
                          ]
                        |)
                      ]
                  |)
                |)))
            |)))
        | _, _ => M.impossible
        end.
      
      (*
      pub fn empty_account(
          token_program_id: &Pubkey,
          token_account: &Pubkey,
          authority: &Pubkey,
          multisig_signers: &[&Pubkey],
          proof_data_location: ProofLocation<ZeroBalanceProofData>,
      ) -> Result<Vec<Instruction>, ProgramError> {
          let mut instructions = vec![inner_empty_account(
              token_program_id,
              token_account,
              authority,
              multisig_signers,
              proof_data_location,
          )?];
      
          if let ProofLocation::InstructionOffset(proof_instruction_offset, proof_data) =
              proof_data_location
          {
              // This constructor appends the proof instruction right after the `EmptyAccount`
              // instruction. This means that the proof instruction offset must be always be
              // 1. To use an arbitrary proof instruction offset, use the
              // `inner_empty_account` constructor.
              let proof_instruction_offset: i8 = proof_instruction_offset.into();
              if proof_instruction_offset != 1 {
                  return Err(TokenError::InvalidProofInstructionOffset.into());
              }
              instructions.push(verify_zero_balance(None, proof_data));
          };
      
          Ok(instructions)
      }
      *)
      Definition empty_account (τ : list Ty.t) (α : list Value.t) : M :=
        match τ, α with
        | [],
            [ token_program_id; token_account; authority; multisig_signers; proof_data_location ] =>
          ltac:(M.monadic
            (let token_program_id := M.alloc (| token_program_id |) in
            let token_account := M.alloc (| token_account |) in
            let authority := M.alloc (| authority |) in
            let multisig_signers := M.alloc (| multisig_signers |) in
            let proof_data_location := M.alloc (| proof_data_location |) in
            M.catch_return (|
              ltac:(M.monadic
                (M.read (|
                  let instructions :=
                    M.alloc (|
                      M.call_closure (|
                        M.get_associated_function (|
                          Ty.apply
                            (Ty.path "slice")
                            [ Ty.path "solana_program::instruction::Instruction" ],
                          "into_vec",
                          [ Ty.path "alloc::alloc::Global" ]
                        |),
                        [
                          (* Unsize *)
                          M.pointer_coercion
                            (M.read (|
                              M.call_closure (|
                                M.get_associated_function (|
                                  Ty.apply
                                    (Ty.path "alloc::boxed::Box")
                                    [
                                      Ty.apply
                                        (Ty.path "array")
                                        [ Ty.path "solana_program::instruction::Instruction" ];
                                      Ty.path "alloc::alloc::Global"
                                    ],
                                  "new",
                                  []
                                |),
                                [
                                  M.alloc (|
                                    Value.Array
                                      [
                                        M.read (|
                                          M.match_operator (|
                                            M.alloc (|
                                              M.call_closure (|
                                                M.get_trait_method (|
                                                  "core::ops::try_trait::Try",
                                                  Ty.apply
                                                    (Ty.path "core::result::Result")
                                                    [
                                                      Ty.path
                                                        "solana_program::instruction::Instruction";
                                                      Ty.path
                                                        "solana_program::program_error::ProgramError"
                                                    ],
                                                  [],
                                                  "branch",
                                                  []
                                                |),
                                                [
                                                  M.call_closure (|
                                                    M.get_function (|
                                                      "spl_token_2022::extension::confidential_transfer::instruction::inner_empty_account",
                                                      []
                                                    |),
                                                    [
                                                      M.read (| token_program_id |);
                                                      M.read (| token_account |);
                                                      M.read (| authority |);
                                                      M.read (| multisig_signers |);
                                                      M.read (| proof_data_location |)
                                                    ]
                                                  |)
                                                ]
                                              |)
                                            |),
                                            [
                                              fun γ =>
                                                ltac:(M.monadic
                                                  (let γ0_0 :=
                                                    M.SubPointer.get_struct_tuple_field (|
                                                      γ,
                                                      "core::ops::control_flow::ControlFlow::Break",
                                                      0
                                                    |) in
                                                  let residual := M.copy (| γ0_0 |) in
                                                  M.alloc (|
                                                    M.never_to_any (|
                                                      M.read (|
                                                        M.return_ (|
                                                          M.call_closure (|
                                                            M.get_trait_method (|
                                                              "core::ops::try_trait::FromResidual",
                                                              Ty.apply
                                                                (Ty.path "core::result::Result")
                                                                [
                                                                  Ty.apply
                                                                    (Ty.path "alloc::vec::Vec")
                                                                    [
                                                                      Ty.path
                                                                        "solana_program::instruction::Instruction";
                                                                      Ty.path "alloc::alloc::Global"
                                                                    ];
                                                                  Ty.path
                                                                    "solana_program::program_error::ProgramError"
                                                                ],
                                                              [
                                                                Ty.apply
                                                                  (Ty.path "core::result::Result")
                                                                  [
                                                                    Ty.path
                                                                      "core::convert::Infallible";
                                                                    Ty.path
                                                                      "solana_program::program_error::ProgramError"
                                                                  ]
                                                              ],
                                                              "from_residual",
                                                              []
                                                            |),
                                                            [ M.read (| residual |) ]
                                                          |)
                                                        |)
                                                      |)
                                                    |)
                                                  |)));
                                              fun γ =>
                                                ltac:(M.monadic
                                                  (let γ0_0 :=
                                                    M.SubPointer.get_struct_tuple_field (|
                                                      γ,
                                                      "core::ops::control_flow::ControlFlow::Continue",
                                                      0
                                                    |) in
                                                  let val := M.copy (| γ0_0 |) in
                                                  val))
                                            ]
                                          |)
                                        |)
                                      ]
                                  |)
                                ]
                              |)
                            |))
                        ]
                      |)
                    |) in
                  let _ :=
                    M.match_operator (|
                      M.alloc (| Value.Tuple [] |),
                      [
                        fun γ =>
                          ltac:(M.monadic
                            (let γ := proof_data_location in
                            let γ0_0 :=
                              M.SubPointer.get_struct_tuple_field (|
                                γ,
                                "spl_token_2022::proof::ProofLocation::InstructionOffset",
                                0
                              |) in
                            let γ0_1 :=
                              M.SubPointer.get_struct_tuple_field (|
                                γ,
                                "spl_token_2022::proof::ProofLocation::InstructionOffset",
                                1
                              |) in
                            let proof_instruction_offset := M.copy (| γ0_0 |) in
                            let proof_data := M.copy (| γ0_1 |) in
                            let proof_instruction_offset :=
                              M.alloc (|
                                M.call_closure (|
                                  M.get_trait_method (|
                                    "core::convert::Into",
                                    Ty.path "core::num::nonzero::NonZeroI8",
                                    [ Ty.path "i8" ],
                                    "into",
                                    []
                                  |),
                                  [ M.read (| proof_instruction_offset |) ]
                                |)
                              |) in
                            let _ :=
                              M.match_operator (|
                                M.alloc (| Value.Tuple [] |),
                                [
                                  fun γ =>
                                    ltac:(M.monadic
                                      (let γ :=
                                        M.use
                                          (M.alloc (|
                                            BinOp.Pure.ne
                                              (M.read (| proof_instruction_offset |))
                                              (Value.Integer 1)
                                          |)) in
                                      let _ :=
                                        M.is_constant_or_break_match (|
                                          M.read (| γ |),
                                          Value.Bool true
                                        |) in
                                      M.alloc (|
                                        M.never_to_any (|
                                          M.read (|
                                            M.return_ (|
                                              Value.StructTuple
                                                "core::result::Result::Err"
                                                [
                                                  M.call_closure (|
                                                    M.get_trait_method (|
                                                      "core::convert::Into",
                                                      Ty.path "spl_token_2022::error::TokenError",
                                                      [
                                                        Ty.path
                                                          "solana_program::program_error::ProgramError"
                                                      ],
                                                      "into",
                                                      []
                                                    |),
                                                    [
                                                      Value.StructTuple
                                                        "spl_token_2022::error::TokenError::InvalidProofInstructionOffset"
                                                        []
                                                    ]
                                                  |)
                                                ]
                                            |)
                                          |)
                                        |)
                                      |)));
                                  fun γ => ltac:(M.monadic (M.alloc (| Value.Tuple [] |)))
                                ]
                              |) in
                            let _ :=
                              M.alloc (|
                                M.call_closure (|
                                  M.get_associated_function (|
                                    Ty.apply
                                      (Ty.path "alloc::vec::Vec")
                                      [
                                        Ty.path "solana_program::instruction::Instruction";
                                        Ty.path "alloc::alloc::Global"
                                      ],
                                    "push",
                                    []
                                  |),
                                  [
                                    instructions;
                                    M.call_closure (|
                                      M.get_function (|
                                        "solana_zk_token_sdk::zk_token_proof_instruction::verify_zero_balance",
                                        []
                                      |),
                                      [
                                        Value.StructTuple "core::option::Option::None" [];
                                        M.read (| proof_data |)
                                      ]
                                    |)
                                  ]
                                |)
                              |) in
                            M.alloc (| Value.Tuple [] |)));
                        fun γ => ltac:(M.monadic (M.alloc (| Value.Tuple [] |)))
                      ]
                    |) in
                  M.alloc (|
                    Value.StructTuple "core::result::Result::Ok" [ M.read (| instructions |) ]
                  |)
                |)))
            |)))
        | _, _ => M.impossible
        end.
      
      (*
      pub fn deposit(
          token_program_id: &Pubkey,
          token_account: &Pubkey,
          mint: &Pubkey,
          amount: u64,
          decimals: u8,
          authority: &Pubkey,
          multisig_signers: &[&Pubkey],
      ) -> Result<Instruction, ProgramError> {
          check_program_account(token_program_id)?;
          let mut accounts = vec![
              AccountMeta::new( *token_account, false),
              AccountMeta::new_readonly( *mint, false),
              AccountMeta::new_readonly( *authority, multisig_signers.is_empty()),
          ];
      
          for multisig_signer in multisig_signers.iter() {
              accounts.push(AccountMeta::new_readonly( **multisig_signer, true));
          }
      
          Ok(encode_instruction(
              token_program_id,
              accounts,
              TokenInstruction::ConfidentialTransferExtension,
              ConfidentialTransferInstruction::Deposit,
              &DepositInstructionData {
                  amount: amount.into(),
                  decimals,
              },
          ))
      }
      *)
      Definition deposit (τ : list Ty.t) (α : list Value.t) : M :=
        match τ, α with
        | [],
            [ token_program_id; token_account; mint; amount; decimals; authority; multisig_signers
            ] =>
          ltac:(M.monadic
            (let token_program_id := M.alloc (| token_program_id |) in
            let token_account := M.alloc (| token_account |) in
            let mint := M.alloc (| mint |) in
            let amount := M.alloc (| amount |) in
            let decimals := M.alloc (| decimals |) in
            let authority := M.alloc (| authority |) in
            let multisig_signers := M.alloc (| multisig_signers |) in
            M.catch_return (|
              ltac:(M.monadic
                (M.read (|
                  let _ :=
                    M.match_operator (|
                      M.alloc (|
                        M.call_closure (|
                          M.get_trait_method (|
                            "core::ops::try_trait::Try",
                            Ty.apply
                              (Ty.path "core::result::Result")
                              [ Ty.tuple []; Ty.path "solana_program::program_error::ProgramError"
                              ],
                            [],
                            "branch",
                            []
                          |),
                          [
                            M.call_closure (|
                              M.get_function (| "spl_token_2022::check_program_account", [] |),
                              [ M.read (| token_program_id |) ]
                            |)
                          ]
                        |)
                      |),
                      [
                        fun γ =>
                          ltac:(M.monadic
                            (let γ0_0 :=
                              M.SubPointer.get_struct_tuple_field (|
                                γ,
                                "core::ops::control_flow::ControlFlow::Break",
                                0
                              |) in
                            let residual := M.copy (| γ0_0 |) in
                            M.alloc (|
                              M.never_to_any (|
                                M.read (|
                                  M.return_ (|
                                    M.call_closure (|
                                      M.get_trait_method (|
                                        "core::ops::try_trait::FromResidual",
                                        Ty.apply
                                          (Ty.path "core::result::Result")
                                          [
                                            Ty.path "solana_program::instruction::Instruction";
                                            Ty.path "solana_program::program_error::ProgramError"
                                          ],
                                        [
                                          Ty.apply
                                            (Ty.path "core::result::Result")
                                            [
                                              Ty.path "core::convert::Infallible";
                                              Ty.path "solana_program::program_error::ProgramError"
                                            ]
                                        ],
                                        "from_residual",
                                        []
                                      |),
                                      [ M.read (| residual |) ]
                                    |)
                                  |)
                                |)
                              |)
                            |)));
                        fun γ =>
                          ltac:(M.monadic
                            (let γ0_0 :=
                              M.SubPointer.get_struct_tuple_field (|
                                γ,
                                "core::ops::control_flow::ControlFlow::Continue",
                                0
                              |) in
                            let val := M.copy (| γ0_0 |) in
                            val))
                      ]
                    |) in
                  let accounts :=
                    M.alloc (|
                      M.call_closure (|
                        M.get_associated_function (|
                          Ty.apply
                            (Ty.path "slice")
                            [ Ty.path "solana_program::instruction::AccountMeta" ],
                          "into_vec",
                          [ Ty.path "alloc::alloc::Global" ]
                        |),
                        [
                          (* Unsize *)
                          M.pointer_coercion
                            (M.read (|
                              M.call_closure (|
                                M.get_associated_function (|
                                  Ty.apply
                                    (Ty.path "alloc::boxed::Box")
                                    [
                                      Ty.apply
                                        (Ty.path "array")
                                        [ Ty.path "solana_program::instruction::AccountMeta" ];
                                      Ty.path "alloc::alloc::Global"
                                    ],
                                  "new",
                                  []
                                |),
                                [
                                  M.alloc (|
                                    Value.Array
                                      [
                                        M.call_closure (|
                                          M.get_associated_function (|
                                            Ty.path "solana_program::instruction::AccountMeta",
                                            "new",
                                            []
                                          |),
                                          [
                                            M.read (| M.read (| token_account |) |);
                                            Value.Bool false
                                          ]
                                        |);
                                        M.call_closure (|
                                          M.get_associated_function (|
                                            Ty.path "solana_program::instruction::AccountMeta",
                                            "new_readonly",
                                            []
                                          |),
                                          [ M.read (| M.read (| mint |) |); Value.Bool false ]
                                        |);
                                        M.call_closure (|
                                          M.get_associated_function (|
                                            Ty.path "solana_program::instruction::AccountMeta",
                                            "new_readonly",
                                            []
                                          |),
                                          [
                                            M.read (| M.read (| authority |) |);
                                            M.call_closure (|
                                              M.get_associated_function (|
                                                Ty.apply
                                                  (Ty.path "slice")
                                                  [
                                                    Ty.apply
                                                      (Ty.path "&")
                                                      [ Ty.path "solana_program::pubkey::Pubkey" ]
                                                  ],
                                                "is_empty",
                                                []
                                              |),
                                              [ M.read (| multisig_signers |) ]
                                            |)
                                          ]
                                        |)
                                      ]
                                  |)
                                ]
                              |)
                            |))
                        ]
                      |)
                    |) in
                  let _ :=
                    M.use
                      (M.match_operator (|
                        M.alloc (|
                          M.call_closure (|
                            M.get_trait_method (|
                              "core::iter::traits::collect::IntoIterator",
                              Ty.apply
                                (Ty.path "core::slice::iter::Iter")
                                [
                                  Ty.apply
                                    (Ty.path "&")
                                    [ Ty.path "solana_program::pubkey::Pubkey" ]
                                ],
                              [],
                              "into_iter",
                              []
                            |),
                            [
                              M.call_closure (|
                                M.get_associated_function (|
                                  Ty.apply
                                    (Ty.path "slice")
                                    [
                                      Ty.apply
                                        (Ty.path "&")
                                        [ Ty.path "solana_program::pubkey::Pubkey" ]
                                    ],
                                  "iter",
                                  []
                                |),
                                [ M.read (| multisig_signers |) ]
                              |)
                            ]
                          |)
                        |),
                        [
                          fun γ =>
                            ltac:(M.monadic
                              (let iter := M.copy (| γ |) in
                              M.loop (|
                                ltac:(M.monadic
                                  (let _ :=
                                    M.match_operator (|
                                      M.alloc (|
                                        M.call_closure (|
                                          M.get_trait_method (|
                                            "core::iter::traits::iterator::Iterator",
                                            Ty.apply
                                              (Ty.path "core::slice::iter::Iter")
                                              [
                                                Ty.apply
                                                  (Ty.path "&")
                                                  [ Ty.path "solana_program::pubkey::Pubkey" ]
                                              ],
                                            [],
                                            "next",
                                            []
                                          |),
                                          [ iter ]
                                        |)
                                      |),
                                      [
                                        fun γ =>
                                          ltac:(M.monadic
                                            (M.alloc (|
                                              M.never_to_any (| M.read (| M.break (||) |) |)
                                            |)));
                                        fun γ =>
                                          ltac:(M.monadic
                                            (let γ0_0 :=
                                              M.SubPointer.get_struct_tuple_field (|
                                                γ,
                                                "core::option::Option::Some",
                                                0
                                              |) in
                                            let multisig_signer := M.copy (| γ0_0 |) in
                                            let _ :=
                                              M.alloc (|
                                                M.call_closure (|
                                                  M.get_associated_function (|
                                                    Ty.apply
                                                      (Ty.path "alloc::vec::Vec")
                                                      [
                                                        Ty.path
                                                          "solana_program::instruction::AccountMeta";
                                                        Ty.path "alloc::alloc::Global"
                                                      ],
                                                    "push",
                                                    []
                                                  |),
                                                  [
                                                    accounts;
                                                    M.call_closure (|
                                                      M.get_associated_function (|
                                                        Ty.path
                                                          "solana_program::instruction::AccountMeta",
                                                        "new_readonly",
                                                        []
                                                      |),
                                                      [
                                                        M.read (|
                                                          M.read (| M.read (| multisig_signer |) |)
                                                        |);
                                                        Value.Bool true
                                                      ]
                                                    |)
                                                  ]
                                                |)
                                              |) in
                                            M.alloc (| Value.Tuple [] |)))
                                      ]
                                    |) in
                                  M.alloc (| Value.Tuple [] |)))
                              |)))
                        ]
                      |)) in
                  M.alloc (|
                    Value.StructTuple
                      "core::result::Result::Ok"
                      [
                        M.call_closure (|
                          M.get_function (|
                            "spl_token_2022::instruction::encode_instruction",
                            [
                              Ty.path
                                "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction";
                              Ty.path
                                "spl_token_2022::extension::confidential_transfer::instruction::DepositInstructionData"
                            ]
                          |),
                          [
                            M.read (| token_program_id |);
                            M.read (| accounts |);
                            Value.StructTuple
                              "spl_token_2022::instruction::TokenInstruction::ConfidentialTransferExtension"
                              [];
                            Value.StructTuple
                              "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction::Deposit"
                              [];
                            M.alloc (|
                              Value.StructRecord
                                "spl_token_2022::extension::confidential_transfer::instruction::DepositInstructionData"
                                [
                                  ("amount",
                                    M.call_closure (|
                                      M.get_trait_method (|
                                        "core::convert::Into",
                                        Ty.path "u64",
                                        [ Ty.path "spl_pod::primitives::PodU64" ],
                                        "into",
                                        []
                                      |),
                                      [ M.read (| amount |) ]
                                    |));
                                  ("decimals", M.read (| decimals |))
                                ]
                            |)
                          ]
                        |)
                      ]
                  |)
                |)))
            |)))
        | _, _ => M.impossible
        end.
      
      (*
      pub fn inner_withdraw(
          token_program_id: &Pubkey,
          token_account: &Pubkey,
          mint: &Pubkey,
          amount: u64,
          decimals: u8,
          new_decryptable_available_balance: DecryptableBalance,
          authority: &Pubkey,
          multisig_signers: &[&Pubkey],
          proof_data_location: ProofLocation<WithdrawData>,
      ) -> Result<Instruction, ProgramError> {
          check_program_account(token_program_id)?;
          let mut accounts = vec![
              AccountMeta::new( *token_account, false),
              AccountMeta::new_readonly( *mint, false),
          ];
      
          let proof_instruction_offset = match proof_data_location {
              ProofLocation::InstructionOffset(proof_instruction_offset, _) => {
                  accounts.push(AccountMeta::new_readonly(sysvar::instructions::id(), false));
                  proof_instruction_offset.into()
              }
              ProofLocation::ContextStateAccount(context_state_account) => {
                  accounts.push(AccountMeta::new_readonly( *context_state_account, false));
                  0
              }
          };
      
          accounts.push(AccountMeta::new_readonly(
              *authority,
              multisig_signers.is_empty(),
          ));
      
          for multisig_signer in multisig_signers.iter() {
              accounts.push(AccountMeta::new_readonly( **multisig_signer, true));
          }
      
          Ok(encode_instruction(
              token_program_id,
              accounts,
              TokenInstruction::ConfidentialTransferExtension,
              ConfidentialTransferInstruction::Withdraw,
              &WithdrawInstructionData {
                  amount: amount.into(),
                  decimals,
                  new_decryptable_available_balance,
                  proof_instruction_offset,
              },
          ))
      }
      *)
      Definition inner_withdraw (τ : list Ty.t) (α : list Value.t) : M :=
        match τ, α with
        | [],
            [
              token_program_id;
              token_account;
              mint;
              amount;
              decimals;
              new_decryptable_available_balance;
              authority;
              multisig_signers;
              proof_data_location
            ] =>
          ltac:(M.monadic
            (let token_program_id := M.alloc (| token_program_id |) in
            let token_account := M.alloc (| token_account |) in
            let mint := M.alloc (| mint |) in
            let amount := M.alloc (| amount |) in
            let decimals := M.alloc (| decimals |) in
            let new_decryptable_available_balance :=
              M.alloc (| new_decryptable_available_balance |) in
            let authority := M.alloc (| authority |) in
            let multisig_signers := M.alloc (| multisig_signers |) in
            let proof_data_location := M.alloc (| proof_data_location |) in
            M.catch_return (|
              ltac:(M.monadic
                (M.read (|
                  let _ :=
                    M.match_operator (|
                      M.alloc (|
                        M.call_closure (|
                          M.get_trait_method (|
                            "core::ops::try_trait::Try",
                            Ty.apply
                              (Ty.path "core::result::Result")
                              [ Ty.tuple []; Ty.path "solana_program::program_error::ProgramError"
                              ],
                            [],
                            "branch",
                            []
                          |),
                          [
                            M.call_closure (|
                              M.get_function (| "spl_token_2022::check_program_account", [] |),
                              [ M.read (| token_program_id |) ]
                            |)
                          ]
                        |)
                      |),
                      [
                        fun γ =>
                          ltac:(M.monadic
                            (let γ0_0 :=
                              M.SubPointer.get_struct_tuple_field (|
                                γ,
                                "core::ops::control_flow::ControlFlow::Break",
                                0
                              |) in
                            let residual := M.copy (| γ0_0 |) in
                            M.alloc (|
                              M.never_to_any (|
                                M.read (|
                                  M.return_ (|
                                    M.call_closure (|
                                      M.get_trait_method (|
                                        "core::ops::try_trait::FromResidual",
                                        Ty.apply
                                          (Ty.path "core::result::Result")
                                          [
                                            Ty.path "solana_program::instruction::Instruction";
                                            Ty.path "solana_program::program_error::ProgramError"
                                          ],
                                        [
                                          Ty.apply
                                            (Ty.path "core::result::Result")
                                            [
                                              Ty.path "core::convert::Infallible";
                                              Ty.path "solana_program::program_error::ProgramError"
                                            ]
                                        ],
                                        "from_residual",
                                        []
                                      |),
                                      [ M.read (| residual |) ]
                                    |)
                                  |)
                                |)
                              |)
                            |)));
                        fun γ =>
                          ltac:(M.monadic
                            (let γ0_0 :=
                              M.SubPointer.get_struct_tuple_field (|
                                γ,
                                "core::ops::control_flow::ControlFlow::Continue",
                                0
                              |) in
                            let val := M.copy (| γ0_0 |) in
                            val))
                      ]
                    |) in
                  let accounts :=
                    M.alloc (|
                      M.call_closure (|
                        M.get_associated_function (|
                          Ty.apply
                            (Ty.path "slice")
                            [ Ty.path "solana_program::instruction::AccountMeta" ],
                          "into_vec",
                          [ Ty.path "alloc::alloc::Global" ]
                        |),
                        [
                          (* Unsize *)
                          M.pointer_coercion
                            (M.read (|
                              M.call_closure (|
                                M.get_associated_function (|
                                  Ty.apply
                                    (Ty.path "alloc::boxed::Box")
                                    [
                                      Ty.apply
                                        (Ty.path "array")
                                        [ Ty.path "solana_program::instruction::AccountMeta" ];
                                      Ty.path "alloc::alloc::Global"
                                    ],
                                  "new",
                                  []
                                |),
                                [
                                  M.alloc (|
                                    Value.Array
                                      [
                                        M.call_closure (|
                                          M.get_associated_function (|
                                            Ty.path "solana_program::instruction::AccountMeta",
                                            "new",
                                            []
                                          |),
                                          [
                                            M.read (| M.read (| token_account |) |);
                                            Value.Bool false
                                          ]
                                        |);
                                        M.call_closure (|
                                          M.get_associated_function (|
                                            Ty.path "solana_program::instruction::AccountMeta",
                                            "new_readonly",
                                            []
                                          |),
                                          [ M.read (| M.read (| mint |) |); Value.Bool false ]
                                        |)
                                      ]
                                  |)
                                ]
                              |)
                            |))
                        ]
                      |)
                    |) in
                  let proof_instruction_offset :=
                    M.copy (|
                      M.match_operator (|
                        proof_data_location,
                        [
                          fun γ =>
                            ltac:(M.monadic
                              (let γ0_0 :=
                                M.SubPointer.get_struct_tuple_field (|
                                  γ,
                                  "spl_token_2022::proof::ProofLocation::InstructionOffset",
                                  0
                                |) in
                              let γ0_1 :=
                                M.SubPointer.get_struct_tuple_field (|
                                  γ,
                                  "spl_token_2022::proof::ProofLocation::InstructionOffset",
                                  1
                                |) in
                              let proof_instruction_offset := M.copy (| γ0_0 |) in
                              let _ :=
                                M.alloc (|
                                  M.call_closure (|
                                    M.get_associated_function (|
                                      Ty.apply
                                        (Ty.path "alloc::vec::Vec")
                                        [
                                          Ty.path "solana_program::instruction::AccountMeta";
                                          Ty.path "alloc::alloc::Global"
                                        ],
                                      "push",
                                      []
                                    |),
                                    [
                                      accounts;
                                      M.call_closure (|
                                        M.get_associated_function (|
                                          Ty.path "solana_program::instruction::AccountMeta",
                                          "new_readonly",
                                          []
                                        |),
                                        [
                                          M.call_closure (|
                                            M.get_function (|
                                              "solana_program::sysvar::instructions::id",
                                              []
                                            |),
                                            []
                                          |);
                                          Value.Bool false
                                        ]
                                      |)
                                    ]
                                  |)
                                |) in
                              M.alloc (|
                                M.call_closure (|
                                  M.get_trait_method (|
                                    "core::convert::Into",
                                    Ty.path "core::num::nonzero::NonZeroI8",
                                    [ Ty.path "i8" ],
                                    "into",
                                    []
                                  |),
                                  [ M.read (| proof_instruction_offset |) ]
                                |)
                              |)));
                          fun γ =>
                            ltac:(M.monadic
                              (let γ0_0 :=
                                M.SubPointer.get_struct_tuple_field (|
                                  γ,
                                  "spl_token_2022::proof::ProofLocation::ContextStateAccount",
                                  0
                                |) in
                              let context_state_account := M.copy (| γ0_0 |) in
                              let _ :=
                                M.alloc (|
                                  M.call_closure (|
                                    M.get_associated_function (|
                                      Ty.apply
                                        (Ty.path "alloc::vec::Vec")
                                        [
                                          Ty.path "solana_program::instruction::AccountMeta";
                                          Ty.path "alloc::alloc::Global"
                                        ],
                                      "push",
                                      []
                                    |),
                                    [
                                      accounts;
                                      M.call_closure (|
                                        M.get_associated_function (|
                                          Ty.path "solana_program::instruction::AccountMeta",
                                          "new_readonly",
                                          []
                                        |),
                                        [
                                          M.read (| M.read (| context_state_account |) |);
                                          Value.Bool false
                                        ]
                                      |)
                                    ]
                                  |)
                                |) in
                              M.alloc (| Value.Integer 0 |)))
                        ]
                      |)
                    |) in
                  let _ :=
                    M.alloc (|
                      M.call_closure (|
                        M.get_associated_function (|
                          Ty.apply
                            (Ty.path "alloc::vec::Vec")
                            [
                              Ty.path "solana_program::instruction::AccountMeta";
                              Ty.path "alloc::alloc::Global"
                            ],
                          "push",
                          []
                        |),
                        [
                          accounts;
                          M.call_closure (|
                            M.get_associated_function (|
                              Ty.path "solana_program::instruction::AccountMeta",
                              "new_readonly",
                              []
                            |),
                            [
                              M.read (| M.read (| authority |) |);
                              M.call_closure (|
                                M.get_associated_function (|
                                  Ty.apply
                                    (Ty.path "slice")
                                    [
                                      Ty.apply
                                        (Ty.path "&")
                                        [ Ty.path "solana_program::pubkey::Pubkey" ]
                                    ],
                                  "is_empty",
                                  []
                                |),
                                [ M.read (| multisig_signers |) ]
                              |)
                            ]
                          |)
                        ]
                      |)
                    |) in
                  let _ :=
                    M.use
                      (M.match_operator (|
                        M.alloc (|
                          M.call_closure (|
                            M.get_trait_method (|
                              "core::iter::traits::collect::IntoIterator",
                              Ty.apply
                                (Ty.path "core::slice::iter::Iter")
                                [
                                  Ty.apply
                                    (Ty.path "&")
                                    [ Ty.path "solana_program::pubkey::Pubkey" ]
                                ],
                              [],
                              "into_iter",
                              []
                            |),
                            [
                              M.call_closure (|
                                M.get_associated_function (|
                                  Ty.apply
                                    (Ty.path "slice")
                                    [
                                      Ty.apply
                                        (Ty.path "&")
                                        [ Ty.path "solana_program::pubkey::Pubkey" ]
                                    ],
                                  "iter",
                                  []
                                |),
                                [ M.read (| multisig_signers |) ]
                              |)
                            ]
                          |)
                        |),
                        [
                          fun γ =>
                            ltac:(M.monadic
                              (let iter := M.copy (| γ |) in
                              M.loop (|
                                ltac:(M.monadic
                                  (let _ :=
                                    M.match_operator (|
                                      M.alloc (|
                                        M.call_closure (|
                                          M.get_trait_method (|
                                            "core::iter::traits::iterator::Iterator",
                                            Ty.apply
                                              (Ty.path "core::slice::iter::Iter")
                                              [
                                                Ty.apply
                                                  (Ty.path "&")
                                                  [ Ty.path "solana_program::pubkey::Pubkey" ]
                                              ],
                                            [],
                                            "next",
                                            []
                                          |),
                                          [ iter ]
                                        |)
                                      |),
                                      [
                                        fun γ =>
                                          ltac:(M.monadic
                                            (M.alloc (|
                                              M.never_to_any (| M.read (| M.break (||) |) |)
                                            |)));
                                        fun γ =>
                                          ltac:(M.monadic
                                            (let γ0_0 :=
                                              M.SubPointer.get_struct_tuple_field (|
                                                γ,
                                                "core::option::Option::Some",
                                                0
                                              |) in
                                            let multisig_signer := M.copy (| γ0_0 |) in
                                            let _ :=
                                              M.alloc (|
                                                M.call_closure (|
                                                  M.get_associated_function (|
                                                    Ty.apply
                                                      (Ty.path "alloc::vec::Vec")
                                                      [
                                                        Ty.path
                                                          "solana_program::instruction::AccountMeta";
                                                        Ty.path "alloc::alloc::Global"
                                                      ],
                                                    "push",
                                                    []
                                                  |),
                                                  [
                                                    accounts;
                                                    M.call_closure (|
                                                      M.get_associated_function (|
                                                        Ty.path
                                                          "solana_program::instruction::AccountMeta",
                                                        "new_readonly",
                                                        []
                                                      |),
                                                      [
                                                        M.read (|
                                                          M.read (| M.read (| multisig_signer |) |)
                                                        |);
                                                        Value.Bool true
                                                      ]
                                                    |)
                                                  ]
                                                |)
                                              |) in
                                            M.alloc (| Value.Tuple [] |)))
                                      ]
                                    |) in
                                  M.alloc (| Value.Tuple [] |)))
                              |)))
                        ]
                      |)) in
                  M.alloc (|
                    Value.StructTuple
                      "core::result::Result::Ok"
                      [
                        M.call_closure (|
                          M.get_function (|
                            "spl_token_2022::instruction::encode_instruction",
                            [
                              Ty.path
                                "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction";
                              Ty.path
                                "spl_token_2022::extension::confidential_transfer::instruction::WithdrawInstructionData"
                            ]
                          |),
                          [
                            M.read (| token_program_id |);
                            M.read (| accounts |);
                            Value.StructTuple
                              "spl_token_2022::instruction::TokenInstruction::ConfidentialTransferExtension"
                              [];
                            Value.StructTuple
                              "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction::Withdraw"
                              [];
                            M.alloc (|
                              Value.StructRecord
                                "spl_token_2022::extension::confidential_transfer::instruction::WithdrawInstructionData"
                                [
                                  ("amount",
                                    M.call_closure (|
                                      M.get_trait_method (|
                                        "core::convert::Into",
                                        Ty.path "u64",
                                        [ Ty.path "spl_pod::primitives::PodU64" ],
                                        "into",
                                        []
                                      |),
                                      [ M.read (| amount |) ]
                                    |));
                                  ("decimals", M.read (| decimals |));
                                  ("new_decryptable_available_balance",
                                    M.read (| new_decryptable_available_balance |));
                                  ("proof_instruction_offset",
                                    M.read (| proof_instruction_offset |))
                                ]
                            |)
                          ]
                        |)
                      ]
                  |)
                |)))
            |)))
        | _, _ => M.impossible
        end.
      
      (*
      pub fn withdraw(
          token_program_id: &Pubkey,
          token_account: &Pubkey,
          mint: &Pubkey,
          amount: u64,
          decimals: u8,
          new_decryptable_available_balance: AeCiphertext,
          authority: &Pubkey,
          multisig_signers: &[&Pubkey],
          proof_data_location: ProofLocation<WithdrawData>,
      ) -> Result<Vec<Instruction>, ProgramError> {
          let mut instructions = vec![inner_withdraw(
              token_program_id,
              token_account,
              mint,
              amount,
              decimals,
              new_decryptable_available_balance.into(),
              authority,
              multisig_signers,
              proof_data_location,
          )?];
      
          if let ProofLocation::InstructionOffset(proof_instruction_offset, proof_data) =
              proof_data_location
          {
              // This constructor appends the proof instruction right after the `Withdraw`
              // instruction. This means that the proof instruction offset must be
              // always be 1. To use an arbitrary proof instruction offset, use the
              // `inner_withdraw` constructor.
              let proof_instruction_offset: i8 = proof_instruction_offset.into();
              if proof_instruction_offset != 1 {
                  return Err(TokenError::InvalidProofInstructionOffset.into());
              }
              instructions.push(verify_withdraw(None, proof_data));
          };
      
          Ok(instructions)
      }
      *)
      Definition withdraw (τ : list Ty.t) (α : list Value.t) : M :=
        match τ, α with
        | [],
            [
              token_program_id;
              token_account;
              mint;
              amount;
              decimals;
              new_decryptable_available_balance;
              authority;
              multisig_signers;
              proof_data_location
            ] =>
          ltac:(M.monadic
            (let token_program_id := M.alloc (| token_program_id |) in
            let token_account := M.alloc (| token_account |) in
            let mint := M.alloc (| mint |) in
            let amount := M.alloc (| amount |) in
            let decimals := M.alloc (| decimals |) in
            let new_decryptable_available_balance :=
              M.alloc (| new_decryptable_available_balance |) in
            let authority := M.alloc (| authority |) in
            let multisig_signers := M.alloc (| multisig_signers |) in
            let proof_data_location := M.alloc (| proof_data_location |) in
            M.catch_return (|
              ltac:(M.monadic
                (M.read (|
                  let instructions :=
                    M.alloc (|
                      M.call_closure (|
                        M.get_associated_function (|
                          Ty.apply
                            (Ty.path "slice")
                            [ Ty.path "solana_program::instruction::Instruction" ],
                          "into_vec",
                          [ Ty.path "alloc::alloc::Global" ]
                        |),
                        [
                          (* Unsize *)
                          M.pointer_coercion
                            (M.read (|
                              M.call_closure (|
                                M.get_associated_function (|
                                  Ty.apply
                                    (Ty.path "alloc::boxed::Box")
                                    [
                                      Ty.apply
                                        (Ty.path "array")
                                        [ Ty.path "solana_program::instruction::Instruction" ];
                                      Ty.path "alloc::alloc::Global"
                                    ],
                                  "new",
                                  []
                                |),
                                [
                                  M.alloc (|
                                    Value.Array
                                      [
                                        M.read (|
                                          M.match_operator (|
                                            M.alloc (|
                                              M.call_closure (|
                                                M.get_trait_method (|
                                                  "core::ops::try_trait::Try",
                                                  Ty.apply
                                                    (Ty.path "core::result::Result")
                                                    [
                                                      Ty.path
                                                        "solana_program::instruction::Instruction";
                                                      Ty.path
                                                        "solana_program::program_error::ProgramError"
                                                    ],
                                                  [],
                                                  "branch",
                                                  []
                                                |),
                                                [
                                                  M.call_closure (|
                                                    M.get_function (|
                                                      "spl_token_2022::extension::confidential_transfer::instruction::inner_withdraw",
                                                      []
                                                    |),
                                                    [
                                                      M.read (| token_program_id |);
                                                      M.read (| token_account |);
                                                      M.read (| mint |);
                                                      M.read (| amount |);
                                                      M.read (| decimals |);
                                                      M.call_closure (|
                                                        M.get_trait_method (|
                                                          "core::convert::Into",
                                                          Ty.path
                                                            "solana_zk_token_sdk::encryption::auth_encryption::AeCiphertext",
                                                          [
                                                            Ty.path
                                                              "solana_zk_token_sdk::zk_token_elgamal::pod::auth_encryption::AeCiphertext"
                                                          ],
                                                          "into",
                                                          []
                                                        |),
                                                        [
                                                          M.read (|
                                                            new_decryptable_available_balance
                                                          |)
                                                        ]
                                                      |);
                                                      M.read (| authority |);
                                                      M.read (| multisig_signers |);
                                                      M.read (| proof_data_location |)
                                                    ]
                                                  |)
                                                ]
                                              |)
                                            |),
                                            [
                                              fun γ =>
                                                ltac:(M.monadic
                                                  (let γ0_0 :=
                                                    M.SubPointer.get_struct_tuple_field (|
                                                      γ,
                                                      "core::ops::control_flow::ControlFlow::Break",
                                                      0
                                                    |) in
                                                  let residual := M.copy (| γ0_0 |) in
                                                  M.alloc (|
                                                    M.never_to_any (|
                                                      M.read (|
                                                        M.return_ (|
                                                          M.call_closure (|
                                                            M.get_trait_method (|
                                                              "core::ops::try_trait::FromResidual",
                                                              Ty.apply
                                                                (Ty.path "core::result::Result")
                                                                [
                                                                  Ty.apply
                                                                    (Ty.path "alloc::vec::Vec")
                                                                    [
                                                                      Ty.path
                                                                        "solana_program::instruction::Instruction";
                                                                      Ty.path "alloc::alloc::Global"
                                                                    ];
                                                                  Ty.path
                                                                    "solana_program::program_error::ProgramError"
                                                                ],
                                                              [
                                                                Ty.apply
                                                                  (Ty.path "core::result::Result")
                                                                  [
                                                                    Ty.path
                                                                      "core::convert::Infallible";
                                                                    Ty.path
                                                                      "solana_program::program_error::ProgramError"
                                                                  ]
                                                              ],
                                                              "from_residual",
                                                              []
                                                            |),
                                                            [ M.read (| residual |) ]
                                                          |)
                                                        |)
                                                      |)
                                                    |)
                                                  |)));
                                              fun γ =>
                                                ltac:(M.monadic
                                                  (let γ0_0 :=
                                                    M.SubPointer.get_struct_tuple_field (|
                                                      γ,
                                                      "core::ops::control_flow::ControlFlow::Continue",
                                                      0
                                                    |) in
                                                  let val := M.copy (| γ0_0 |) in
                                                  val))
                                            ]
                                          |)
                                        |)
                                      ]
                                  |)
                                ]
                              |)
                            |))
                        ]
                      |)
                    |) in
                  let _ :=
                    M.match_operator (|
                      M.alloc (| Value.Tuple [] |),
                      [
                        fun γ =>
                          ltac:(M.monadic
                            (let γ := proof_data_location in
                            let γ0_0 :=
                              M.SubPointer.get_struct_tuple_field (|
                                γ,
                                "spl_token_2022::proof::ProofLocation::InstructionOffset",
                                0
                              |) in
                            let γ0_1 :=
                              M.SubPointer.get_struct_tuple_field (|
                                γ,
                                "spl_token_2022::proof::ProofLocation::InstructionOffset",
                                1
                              |) in
                            let proof_instruction_offset := M.copy (| γ0_0 |) in
                            let proof_data := M.copy (| γ0_1 |) in
                            let proof_instruction_offset :=
                              M.alloc (|
                                M.call_closure (|
                                  M.get_trait_method (|
                                    "core::convert::Into",
                                    Ty.path "core::num::nonzero::NonZeroI8",
                                    [ Ty.path "i8" ],
                                    "into",
                                    []
                                  |),
                                  [ M.read (| proof_instruction_offset |) ]
                                |)
                              |) in
                            let _ :=
                              M.match_operator (|
                                M.alloc (| Value.Tuple [] |),
                                [
                                  fun γ =>
                                    ltac:(M.monadic
                                      (let γ :=
                                        M.use
                                          (M.alloc (|
                                            BinOp.Pure.ne
                                              (M.read (| proof_instruction_offset |))
                                              (Value.Integer 1)
                                          |)) in
                                      let _ :=
                                        M.is_constant_or_break_match (|
                                          M.read (| γ |),
                                          Value.Bool true
                                        |) in
                                      M.alloc (|
                                        M.never_to_any (|
                                          M.read (|
                                            M.return_ (|
                                              Value.StructTuple
                                                "core::result::Result::Err"
                                                [
                                                  M.call_closure (|
                                                    M.get_trait_method (|
                                                      "core::convert::Into",
                                                      Ty.path "spl_token_2022::error::TokenError",
                                                      [
                                                        Ty.path
                                                          "solana_program::program_error::ProgramError"
                                                      ],
                                                      "into",
                                                      []
                                                    |),
                                                    [
                                                      Value.StructTuple
                                                        "spl_token_2022::error::TokenError::InvalidProofInstructionOffset"
                                                        []
                                                    ]
                                                  |)
                                                ]
                                            |)
                                          |)
                                        |)
                                      |)));
                                  fun γ => ltac:(M.monadic (M.alloc (| Value.Tuple [] |)))
                                ]
                              |) in
                            let _ :=
                              M.alloc (|
                                M.call_closure (|
                                  M.get_associated_function (|
                                    Ty.apply
                                      (Ty.path "alloc::vec::Vec")
                                      [
                                        Ty.path "solana_program::instruction::Instruction";
                                        Ty.path "alloc::alloc::Global"
                                      ],
                                    "push",
                                    []
                                  |),
                                  [
                                    instructions;
                                    M.call_closure (|
                                      M.get_function (|
                                        "solana_zk_token_sdk::zk_token_proof_instruction::verify_withdraw",
                                        []
                                      |),
                                      [
                                        Value.StructTuple "core::option::Option::None" [];
                                        M.read (| proof_data |)
                                      ]
                                    |)
                                  ]
                                |)
                              |) in
                            M.alloc (| Value.Tuple [] |)));
                        fun γ => ltac:(M.monadic (M.alloc (| Value.Tuple [] |)))
                      ]
                    |) in
                  M.alloc (|
                    Value.StructTuple "core::result::Result::Ok" [ M.read (| instructions |) ]
                  |)
                |)))
            |)))
        | _, _ => M.impossible
        end.
      
      (*
      pub fn inner_transfer(
          token_program_id: &Pubkey,
          source_token_account: &Pubkey,
          mint: &Pubkey,
          destination_token_account: &Pubkey,
          new_source_decryptable_available_balance: DecryptableBalance,
          authority: &Pubkey,
          multisig_signers: &[&Pubkey],
          proof_data_location: ProofLocation<TransferData>,
      ) -> Result<Instruction, ProgramError> {
          check_program_account(token_program_id)?;
          let mut accounts = vec![
              AccountMeta::new( *source_token_account, false),
              AccountMeta::new_readonly( *mint, false),
              AccountMeta::new( *destination_token_account, false),
          ];
      
          let proof_instruction_offset = match proof_data_location {
              ProofLocation::InstructionOffset(proof_instruction_offset, _) => {
                  accounts.push(AccountMeta::new_readonly(sysvar::instructions::id(), false));
                  proof_instruction_offset.into()
              }
              ProofLocation::ContextStateAccount(context_state_account) => {
                  accounts.push(AccountMeta::new_readonly( *context_state_account, false));
                  0
              }
          };
      
          accounts.push(AccountMeta::new_readonly(
              *authority,
              multisig_signers.is_empty(),
          ));
      
          for multisig_signer in multisig_signers.iter() {
              accounts.push(AccountMeta::new_readonly( **multisig_signer, true));
          }
      
          Ok(encode_instruction(
              token_program_id,
              accounts,
              TokenInstruction::ConfidentialTransferExtension,
              ConfidentialTransferInstruction::Transfer,
              &TransferInstructionData {
                  new_source_decryptable_available_balance,
                  proof_instruction_offset,
              },
          ))
      }
      *)
      Definition inner_transfer (τ : list Ty.t) (α : list Value.t) : M :=
        match τ, α with
        | [],
            [
              token_program_id;
              source_token_account;
              mint;
              destination_token_account;
              new_source_decryptable_available_balance;
              authority;
              multisig_signers;
              proof_data_location
            ] =>
          ltac:(M.monadic
            (let token_program_id := M.alloc (| token_program_id |) in
            let source_token_account := M.alloc (| source_token_account |) in
            let mint := M.alloc (| mint |) in
            let destination_token_account := M.alloc (| destination_token_account |) in
            let new_source_decryptable_available_balance :=
              M.alloc (| new_source_decryptable_available_balance |) in
            let authority := M.alloc (| authority |) in
            let multisig_signers := M.alloc (| multisig_signers |) in
            let proof_data_location := M.alloc (| proof_data_location |) in
            M.catch_return (|
              ltac:(M.monadic
                (M.read (|
                  let _ :=
                    M.match_operator (|
                      M.alloc (|
                        M.call_closure (|
                          M.get_trait_method (|
                            "core::ops::try_trait::Try",
                            Ty.apply
                              (Ty.path "core::result::Result")
                              [ Ty.tuple []; Ty.path "solana_program::program_error::ProgramError"
                              ],
                            [],
                            "branch",
                            []
                          |),
                          [
                            M.call_closure (|
                              M.get_function (| "spl_token_2022::check_program_account", [] |),
                              [ M.read (| token_program_id |) ]
                            |)
                          ]
                        |)
                      |),
                      [
                        fun γ =>
                          ltac:(M.monadic
                            (let γ0_0 :=
                              M.SubPointer.get_struct_tuple_field (|
                                γ,
                                "core::ops::control_flow::ControlFlow::Break",
                                0
                              |) in
                            let residual := M.copy (| γ0_0 |) in
                            M.alloc (|
                              M.never_to_any (|
                                M.read (|
                                  M.return_ (|
                                    M.call_closure (|
                                      M.get_trait_method (|
                                        "core::ops::try_trait::FromResidual",
                                        Ty.apply
                                          (Ty.path "core::result::Result")
                                          [
                                            Ty.path "solana_program::instruction::Instruction";
                                            Ty.path "solana_program::program_error::ProgramError"
                                          ],
                                        [
                                          Ty.apply
                                            (Ty.path "core::result::Result")
                                            [
                                              Ty.path "core::convert::Infallible";
                                              Ty.path "solana_program::program_error::ProgramError"
                                            ]
                                        ],
                                        "from_residual",
                                        []
                                      |),
                                      [ M.read (| residual |) ]
                                    |)
                                  |)
                                |)
                              |)
                            |)));
                        fun γ =>
                          ltac:(M.monadic
                            (let γ0_0 :=
                              M.SubPointer.get_struct_tuple_field (|
                                γ,
                                "core::ops::control_flow::ControlFlow::Continue",
                                0
                              |) in
                            let val := M.copy (| γ0_0 |) in
                            val))
                      ]
                    |) in
                  let accounts :=
                    M.alloc (|
                      M.call_closure (|
                        M.get_associated_function (|
                          Ty.apply
                            (Ty.path "slice")
                            [ Ty.path "solana_program::instruction::AccountMeta" ],
                          "into_vec",
                          [ Ty.path "alloc::alloc::Global" ]
                        |),
                        [
                          (* Unsize *)
                          M.pointer_coercion
                            (M.read (|
                              M.call_closure (|
                                M.get_associated_function (|
                                  Ty.apply
                                    (Ty.path "alloc::boxed::Box")
                                    [
                                      Ty.apply
                                        (Ty.path "array")
                                        [ Ty.path "solana_program::instruction::AccountMeta" ];
                                      Ty.path "alloc::alloc::Global"
                                    ],
                                  "new",
                                  []
                                |),
                                [
                                  M.alloc (|
                                    Value.Array
                                      [
                                        M.call_closure (|
                                          M.get_associated_function (|
                                            Ty.path "solana_program::instruction::AccountMeta",
                                            "new",
                                            []
                                          |),
                                          [
                                            M.read (| M.read (| source_token_account |) |);
                                            Value.Bool false
                                          ]
                                        |);
                                        M.call_closure (|
                                          M.get_associated_function (|
                                            Ty.path "solana_program::instruction::AccountMeta",
                                            "new_readonly",
                                            []
                                          |),
                                          [ M.read (| M.read (| mint |) |); Value.Bool false ]
                                        |);
                                        M.call_closure (|
                                          M.get_associated_function (|
                                            Ty.path "solana_program::instruction::AccountMeta",
                                            "new",
                                            []
                                          |),
                                          [
                                            M.read (| M.read (| destination_token_account |) |);
                                            Value.Bool false
                                          ]
                                        |)
                                      ]
                                  |)
                                ]
                              |)
                            |))
                        ]
                      |)
                    |) in
                  let proof_instruction_offset :=
                    M.copy (|
                      M.match_operator (|
                        proof_data_location,
                        [
                          fun γ =>
                            ltac:(M.monadic
                              (let γ0_0 :=
                                M.SubPointer.get_struct_tuple_field (|
                                  γ,
                                  "spl_token_2022::proof::ProofLocation::InstructionOffset",
                                  0
                                |) in
                              let γ0_1 :=
                                M.SubPointer.get_struct_tuple_field (|
                                  γ,
                                  "spl_token_2022::proof::ProofLocation::InstructionOffset",
                                  1
                                |) in
                              let proof_instruction_offset := M.copy (| γ0_0 |) in
                              let _ :=
                                M.alloc (|
                                  M.call_closure (|
                                    M.get_associated_function (|
                                      Ty.apply
                                        (Ty.path "alloc::vec::Vec")
                                        [
                                          Ty.path "solana_program::instruction::AccountMeta";
                                          Ty.path "alloc::alloc::Global"
                                        ],
                                      "push",
                                      []
                                    |),
                                    [
                                      accounts;
                                      M.call_closure (|
                                        M.get_associated_function (|
                                          Ty.path "solana_program::instruction::AccountMeta",
                                          "new_readonly",
                                          []
                                        |),
                                        [
                                          M.call_closure (|
                                            M.get_function (|
                                              "solana_program::sysvar::instructions::id",
                                              []
                                            |),
                                            []
                                          |);
                                          Value.Bool false
                                        ]
                                      |)
                                    ]
                                  |)
                                |) in
                              M.alloc (|
                                M.call_closure (|
                                  M.get_trait_method (|
                                    "core::convert::Into",
                                    Ty.path "core::num::nonzero::NonZeroI8",
                                    [ Ty.path "i8" ],
                                    "into",
                                    []
                                  |),
                                  [ M.read (| proof_instruction_offset |) ]
                                |)
                              |)));
                          fun γ =>
                            ltac:(M.monadic
                              (let γ0_0 :=
                                M.SubPointer.get_struct_tuple_field (|
                                  γ,
                                  "spl_token_2022::proof::ProofLocation::ContextStateAccount",
                                  0
                                |) in
                              let context_state_account := M.copy (| γ0_0 |) in
                              let _ :=
                                M.alloc (|
                                  M.call_closure (|
                                    M.get_associated_function (|
                                      Ty.apply
                                        (Ty.path "alloc::vec::Vec")
                                        [
                                          Ty.path "solana_program::instruction::AccountMeta";
                                          Ty.path "alloc::alloc::Global"
                                        ],
                                      "push",
                                      []
                                    |),
                                    [
                                      accounts;
                                      M.call_closure (|
                                        M.get_associated_function (|
                                          Ty.path "solana_program::instruction::AccountMeta",
                                          "new_readonly",
                                          []
                                        |),
                                        [
                                          M.read (| M.read (| context_state_account |) |);
                                          Value.Bool false
                                        ]
                                      |)
                                    ]
                                  |)
                                |) in
                              M.alloc (| Value.Integer 0 |)))
                        ]
                      |)
                    |) in
                  let _ :=
                    M.alloc (|
                      M.call_closure (|
                        M.get_associated_function (|
                          Ty.apply
                            (Ty.path "alloc::vec::Vec")
                            [
                              Ty.path "solana_program::instruction::AccountMeta";
                              Ty.path "alloc::alloc::Global"
                            ],
                          "push",
                          []
                        |),
                        [
                          accounts;
                          M.call_closure (|
                            M.get_associated_function (|
                              Ty.path "solana_program::instruction::AccountMeta",
                              "new_readonly",
                              []
                            |),
                            [
                              M.read (| M.read (| authority |) |);
                              M.call_closure (|
                                M.get_associated_function (|
                                  Ty.apply
                                    (Ty.path "slice")
                                    [
                                      Ty.apply
                                        (Ty.path "&")
                                        [ Ty.path "solana_program::pubkey::Pubkey" ]
                                    ],
                                  "is_empty",
                                  []
                                |),
                                [ M.read (| multisig_signers |) ]
                              |)
                            ]
                          |)
                        ]
                      |)
                    |) in
                  let _ :=
                    M.use
                      (M.match_operator (|
                        M.alloc (|
                          M.call_closure (|
                            M.get_trait_method (|
                              "core::iter::traits::collect::IntoIterator",
                              Ty.apply
                                (Ty.path "core::slice::iter::Iter")
                                [
                                  Ty.apply
                                    (Ty.path "&")
                                    [ Ty.path "solana_program::pubkey::Pubkey" ]
                                ],
                              [],
                              "into_iter",
                              []
                            |),
                            [
                              M.call_closure (|
                                M.get_associated_function (|
                                  Ty.apply
                                    (Ty.path "slice")
                                    [
                                      Ty.apply
                                        (Ty.path "&")
                                        [ Ty.path "solana_program::pubkey::Pubkey" ]
                                    ],
                                  "iter",
                                  []
                                |),
                                [ M.read (| multisig_signers |) ]
                              |)
                            ]
                          |)
                        |),
                        [
                          fun γ =>
                            ltac:(M.monadic
                              (let iter := M.copy (| γ |) in
                              M.loop (|
                                ltac:(M.monadic
                                  (let _ :=
                                    M.match_operator (|
                                      M.alloc (|
                                        M.call_closure (|
                                          M.get_trait_method (|
                                            "core::iter::traits::iterator::Iterator",
                                            Ty.apply
                                              (Ty.path "core::slice::iter::Iter")
                                              [
                                                Ty.apply
                                                  (Ty.path "&")
                                                  [ Ty.path "solana_program::pubkey::Pubkey" ]
                                              ],
                                            [],
                                            "next",
                                            []
                                          |),
                                          [ iter ]
                                        |)
                                      |),
                                      [
                                        fun γ =>
                                          ltac:(M.monadic
                                            (M.alloc (|
                                              M.never_to_any (| M.read (| M.break (||) |) |)
                                            |)));
                                        fun γ =>
                                          ltac:(M.monadic
                                            (let γ0_0 :=
                                              M.SubPointer.get_struct_tuple_field (|
                                                γ,
                                                "core::option::Option::Some",
                                                0
                                              |) in
                                            let multisig_signer := M.copy (| γ0_0 |) in
                                            let _ :=
                                              M.alloc (|
                                                M.call_closure (|
                                                  M.get_associated_function (|
                                                    Ty.apply
                                                      (Ty.path "alloc::vec::Vec")
                                                      [
                                                        Ty.path
                                                          "solana_program::instruction::AccountMeta";
                                                        Ty.path "alloc::alloc::Global"
                                                      ],
                                                    "push",
                                                    []
                                                  |),
                                                  [
                                                    accounts;
                                                    M.call_closure (|
                                                      M.get_associated_function (|
                                                        Ty.path
                                                          "solana_program::instruction::AccountMeta",
                                                        "new_readonly",
                                                        []
                                                      |),
                                                      [
                                                        M.read (|
                                                          M.read (| M.read (| multisig_signer |) |)
                                                        |);
                                                        Value.Bool true
                                                      ]
                                                    |)
                                                  ]
                                                |)
                                              |) in
                                            M.alloc (| Value.Tuple [] |)))
                                      ]
                                    |) in
                                  M.alloc (| Value.Tuple [] |)))
                              |)))
                        ]
                      |)) in
                  M.alloc (|
                    Value.StructTuple
                      "core::result::Result::Ok"
                      [
                        M.call_closure (|
                          M.get_function (|
                            "spl_token_2022::instruction::encode_instruction",
                            [
                              Ty.path
                                "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction";
                              Ty.path
                                "spl_token_2022::extension::confidential_transfer::instruction::TransferInstructionData"
                            ]
                          |),
                          [
                            M.read (| token_program_id |);
                            M.read (| accounts |);
                            Value.StructTuple
                              "spl_token_2022::instruction::TokenInstruction::ConfidentialTransferExtension"
                              [];
                            Value.StructTuple
                              "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction::Transfer"
                              [];
                            M.alloc (|
                              Value.StructRecord
                                "spl_token_2022::extension::confidential_transfer::instruction::TransferInstructionData"
                                [
                                  ("new_source_decryptable_available_balance",
                                    M.read (| new_source_decryptable_available_balance |));
                                  ("proof_instruction_offset",
                                    M.read (| proof_instruction_offset |))
                                ]
                            |)
                          ]
                        |)
                      ]
                  |)
                |)))
            |)))
        | _, _ => M.impossible
        end.
      
      (*
      pub fn transfer(
          token_program_id: &Pubkey,
          source_token_account: &Pubkey,
          mint: &Pubkey,
          destination_token_account: &Pubkey,
          new_source_decryptable_available_balance: AeCiphertext,
          authority: &Pubkey,
          multisig_signers: &[&Pubkey],
          proof_data_location: ProofLocation<TransferData>,
      ) -> Result<Vec<Instruction>, ProgramError> {
          let mut instructions = vec![inner_transfer(
              token_program_id,
              source_token_account,
              mint,
              destination_token_account,
              new_source_decryptable_available_balance.into(),
              authority,
              multisig_signers,
              proof_data_location,
          )?];
      
          if let ProofLocation::InstructionOffset(proof_instruction_offset, proof_data) =
              proof_data_location
          {
              // This constructor appends the proof instruction right after the `Transfer`
              // instruction. This means that the proof instruction offset must be
              // always be 1. To use an arbitrary proof instruction offset, use the
              // `inner_transfer` constructor.
              let proof_instruction_offset: i8 = proof_instruction_offset.into();
              if proof_instruction_offset != 1 {
                  return Err(TokenError::InvalidProofInstructionOffset.into());
              }
              instructions.push(verify_transfer(None, proof_data));
          };
      
          Ok(instructions)
      }
      *)
      Definition transfer (τ : list Ty.t) (α : list Value.t) : M :=
        match τ, α with
        | [],
            [
              token_program_id;
              source_token_account;
              mint;
              destination_token_account;
              new_source_decryptable_available_balance;
              authority;
              multisig_signers;
              proof_data_location
            ] =>
          ltac:(M.monadic
            (let token_program_id := M.alloc (| token_program_id |) in
            let source_token_account := M.alloc (| source_token_account |) in
            let mint := M.alloc (| mint |) in
            let destination_token_account := M.alloc (| destination_token_account |) in
            let new_source_decryptable_available_balance :=
              M.alloc (| new_source_decryptable_available_balance |) in
            let authority := M.alloc (| authority |) in
            let multisig_signers := M.alloc (| multisig_signers |) in
            let proof_data_location := M.alloc (| proof_data_location |) in
            M.catch_return (|
              ltac:(M.monadic
                (M.read (|
                  let instructions :=
                    M.alloc (|
                      M.call_closure (|
                        M.get_associated_function (|
                          Ty.apply
                            (Ty.path "slice")
                            [ Ty.path "solana_program::instruction::Instruction" ],
                          "into_vec",
                          [ Ty.path "alloc::alloc::Global" ]
                        |),
                        [
                          (* Unsize *)
                          M.pointer_coercion
                            (M.read (|
                              M.call_closure (|
                                M.get_associated_function (|
                                  Ty.apply
                                    (Ty.path "alloc::boxed::Box")
                                    [
                                      Ty.apply
                                        (Ty.path "array")
                                        [ Ty.path "solana_program::instruction::Instruction" ];
                                      Ty.path "alloc::alloc::Global"
                                    ],
                                  "new",
                                  []
                                |),
                                [
                                  M.alloc (|
                                    Value.Array
                                      [
                                        M.read (|
                                          M.match_operator (|
                                            M.alloc (|
                                              M.call_closure (|
                                                M.get_trait_method (|
                                                  "core::ops::try_trait::Try",
                                                  Ty.apply
                                                    (Ty.path "core::result::Result")
                                                    [
                                                      Ty.path
                                                        "solana_program::instruction::Instruction";
                                                      Ty.path
                                                        "solana_program::program_error::ProgramError"
                                                    ],
                                                  [],
                                                  "branch",
                                                  []
                                                |),
                                                [
                                                  M.call_closure (|
                                                    M.get_function (|
                                                      "spl_token_2022::extension::confidential_transfer::instruction::inner_transfer",
                                                      []
                                                    |),
                                                    [
                                                      M.read (| token_program_id |);
                                                      M.read (| source_token_account |);
                                                      M.read (| mint |);
                                                      M.read (| destination_token_account |);
                                                      M.call_closure (|
                                                        M.get_trait_method (|
                                                          "core::convert::Into",
                                                          Ty.path
                                                            "solana_zk_token_sdk::encryption::auth_encryption::AeCiphertext",
                                                          [
                                                            Ty.path
                                                              "solana_zk_token_sdk::zk_token_elgamal::pod::auth_encryption::AeCiphertext"
                                                          ],
                                                          "into",
                                                          []
                                                        |),
                                                        [
                                                          M.read (|
                                                            new_source_decryptable_available_balance
                                                          |)
                                                        ]
                                                      |);
                                                      M.read (| authority |);
                                                      M.read (| multisig_signers |);
                                                      M.read (| proof_data_location |)
                                                    ]
                                                  |)
                                                ]
                                              |)
                                            |),
                                            [
                                              fun γ =>
                                                ltac:(M.monadic
                                                  (let γ0_0 :=
                                                    M.SubPointer.get_struct_tuple_field (|
                                                      γ,
                                                      "core::ops::control_flow::ControlFlow::Break",
                                                      0
                                                    |) in
                                                  let residual := M.copy (| γ0_0 |) in
                                                  M.alloc (|
                                                    M.never_to_any (|
                                                      M.read (|
                                                        M.return_ (|
                                                          M.call_closure (|
                                                            M.get_trait_method (|
                                                              "core::ops::try_trait::FromResidual",
                                                              Ty.apply
                                                                (Ty.path "core::result::Result")
                                                                [
                                                                  Ty.apply
                                                                    (Ty.path "alloc::vec::Vec")
                                                                    [
                                                                      Ty.path
                                                                        "solana_program::instruction::Instruction";
                                                                      Ty.path "alloc::alloc::Global"
                                                                    ];
                                                                  Ty.path
                                                                    "solana_program::program_error::ProgramError"
                                                                ],
                                                              [
                                                                Ty.apply
                                                                  (Ty.path "core::result::Result")
                                                                  [
                                                                    Ty.path
                                                                      "core::convert::Infallible";
                                                                    Ty.path
                                                                      "solana_program::program_error::ProgramError"
                                                                  ]
                                                              ],
                                                              "from_residual",
                                                              []
                                                            |),
                                                            [ M.read (| residual |) ]
                                                          |)
                                                        |)
                                                      |)
                                                    |)
                                                  |)));
                                              fun γ =>
                                                ltac:(M.monadic
                                                  (let γ0_0 :=
                                                    M.SubPointer.get_struct_tuple_field (|
                                                      γ,
                                                      "core::ops::control_flow::ControlFlow::Continue",
                                                      0
                                                    |) in
                                                  let val := M.copy (| γ0_0 |) in
                                                  val))
                                            ]
                                          |)
                                        |)
                                      ]
                                  |)
                                ]
                              |)
                            |))
                        ]
                      |)
                    |) in
                  let _ :=
                    M.match_operator (|
                      M.alloc (| Value.Tuple [] |),
                      [
                        fun γ =>
                          ltac:(M.monadic
                            (let γ := proof_data_location in
                            let γ0_0 :=
                              M.SubPointer.get_struct_tuple_field (|
                                γ,
                                "spl_token_2022::proof::ProofLocation::InstructionOffset",
                                0
                              |) in
                            let γ0_1 :=
                              M.SubPointer.get_struct_tuple_field (|
                                γ,
                                "spl_token_2022::proof::ProofLocation::InstructionOffset",
                                1
                              |) in
                            let proof_instruction_offset := M.copy (| γ0_0 |) in
                            let proof_data := M.copy (| γ0_1 |) in
                            let proof_instruction_offset :=
                              M.alloc (|
                                M.call_closure (|
                                  M.get_trait_method (|
                                    "core::convert::Into",
                                    Ty.path "core::num::nonzero::NonZeroI8",
                                    [ Ty.path "i8" ],
                                    "into",
                                    []
                                  |),
                                  [ M.read (| proof_instruction_offset |) ]
                                |)
                              |) in
                            let _ :=
                              M.match_operator (|
                                M.alloc (| Value.Tuple [] |),
                                [
                                  fun γ =>
                                    ltac:(M.monadic
                                      (let γ :=
                                        M.use
                                          (M.alloc (|
                                            BinOp.Pure.ne
                                              (M.read (| proof_instruction_offset |))
                                              (Value.Integer 1)
                                          |)) in
                                      let _ :=
                                        M.is_constant_or_break_match (|
                                          M.read (| γ |),
                                          Value.Bool true
                                        |) in
                                      M.alloc (|
                                        M.never_to_any (|
                                          M.read (|
                                            M.return_ (|
                                              Value.StructTuple
                                                "core::result::Result::Err"
                                                [
                                                  M.call_closure (|
                                                    M.get_trait_method (|
                                                      "core::convert::Into",
                                                      Ty.path "spl_token_2022::error::TokenError",
                                                      [
                                                        Ty.path
                                                          "solana_program::program_error::ProgramError"
                                                      ],
                                                      "into",
                                                      []
                                                    |),
                                                    [
                                                      Value.StructTuple
                                                        "spl_token_2022::error::TokenError::InvalidProofInstructionOffset"
                                                        []
                                                    ]
                                                  |)
                                                ]
                                            |)
                                          |)
                                        |)
                                      |)));
                                  fun γ => ltac:(M.monadic (M.alloc (| Value.Tuple [] |)))
                                ]
                              |) in
                            let _ :=
                              M.alloc (|
                                M.call_closure (|
                                  M.get_associated_function (|
                                    Ty.apply
                                      (Ty.path "alloc::vec::Vec")
                                      [
                                        Ty.path "solana_program::instruction::Instruction";
                                        Ty.path "alloc::alloc::Global"
                                      ],
                                    "push",
                                    []
                                  |),
                                  [
                                    instructions;
                                    M.call_closure (|
                                      M.get_function (|
                                        "solana_zk_token_sdk::zk_token_proof_instruction::verify_transfer",
                                        []
                                      |),
                                      [
                                        Value.StructTuple "core::option::Option::None" [];
                                        M.read (| proof_data |)
                                      ]
                                    |)
                                  ]
                                |)
                              |) in
                            M.alloc (| Value.Tuple [] |)));
                        fun γ => ltac:(M.monadic (M.alloc (| Value.Tuple [] |)))
                      ]
                    |) in
                  M.alloc (|
                    Value.StructTuple "core::result::Result::Ok" [ M.read (| instructions |) ]
                  |)
                |)))
            |)))
        | _, _ => M.impossible
        end.
      
      (*
      pub fn inner_transfer_with_fee(
          token_program_id: &Pubkey,
          source_token_account: &Pubkey,
          mint: &Pubkey,
          destination_token_account: &Pubkey,
          new_source_decryptable_available_balance: DecryptableBalance,
          authority: &Pubkey,
          multisig_signers: &[&Pubkey],
          proof_data_location: ProofLocation<TransferWithFeeData>,
      ) -> Result<Instruction, ProgramError> {
          check_program_account(token_program_id)?;
          let mut accounts = vec![
              AccountMeta::new( *source_token_account, false),
              AccountMeta::new_readonly( *mint, false),
              AccountMeta::new( *destination_token_account, false),
          ];
      
          let proof_instruction_offset = match proof_data_location {
              ProofLocation::InstructionOffset(proof_instruction_offset, _) => {
                  accounts.push(AccountMeta::new_readonly(sysvar::instructions::id(), false));
                  proof_instruction_offset.into()
              }
              ProofLocation::ContextStateAccount(context_state_account) => {
                  accounts.push(AccountMeta::new_readonly( *context_state_account, false));
                  0
              }
          };
      
          accounts.push(AccountMeta::new_readonly(
              *authority,
              multisig_signers.is_empty(),
          ));
      
          for multisig_signer in multisig_signers.iter() {
              accounts.push(AccountMeta::new_readonly( **multisig_signer, true));
          }
      
          Ok(encode_instruction(
              token_program_id,
              accounts,
              TokenInstruction::ConfidentialTransferExtension,
              ConfidentialTransferInstruction::Transfer,
              &TransferInstructionData {
                  new_source_decryptable_available_balance,
                  proof_instruction_offset,
              },
          ))
      }
      *)
      Definition inner_transfer_with_fee (τ : list Ty.t) (α : list Value.t) : M :=
        match τ, α with
        | [],
            [
              token_program_id;
              source_token_account;
              mint;
              destination_token_account;
              new_source_decryptable_available_balance;
              authority;
              multisig_signers;
              proof_data_location
            ] =>
          ltac:(M.monadic
            (let token_program_id := M.alloc (| token_program_id |) in
            let source_token_account := M.alloc (| source_token_account |) in
            let mint := M.alloc (| mint |) in
            let destination_token_account := M.alloc (| destination_token_account |) in
            let new_source_decryptable_available_balance :=
              M.alloc (| new_source_decryptable_available_balance |) in
            let authority := M.alloc (| authority |) in
            let multisig_signers := M.alloc (| multisig_signers |) in
            let proof_data_location := M.alloc (| proof_data_location |) in
            M.catch_return (|
              ltac:(M.monadic
                (M.read (|
                  let _ :=
                    M.match_operator (|
                      M.alloc (|
                        M.call_closure (|
                          M.get_trait_method (|
                            "core::ops::try_trait::Try",
                            Ty.apply
                              (Ty.path "core::result::Result")
                              [ Ty.tuple []; Ty.path "solana_program::program_error::ProgramError"
                              ],
                            [],
                            "branch",
                            []
                          |),
                          [
                            M.call_closure (|
                              M.get_function (| "spl_token_2022::check_program_account", [] |),
                              [ M.read (| token_program_id |) ]
                            |)
                          ]
                        |)
                      |),
                      [
                        fun γ =>
                          ltac:(M.monadic
                            (let γ0_0 :=
                              M.SubPointer.get_struct_tuple_field (|
                                γ,
                                "core::ops::control_flow::ControlFlow::Break",
                                0
                              |) in
                            let residual := M.copy (| γ0_0 |) in
                            M.alloc (|
                              M.never_to_any (|
                                M.read (|
                                  M.return_ (|
                                    M.call_closure (|
                                      M.get_trait_method (|
                                        "core::ops::try_trait::FromResidual",
                                        Ty.apply
                                          (Ty.path "core::result::Result")
                                          [
                                            Ty.path "solana_program::instruction::Instruction";
                                            Ty.path "solana_program::program_error::ProgramError"
                                          ],
                                        [
                                          Ty.apply
                                            (Ty.path "core::result::Result")
                                            [
                                              Ty.path "core::convert::Infallible";
                                              Ty.path "solana_program::program_error::ProgramError"
                                            ]
                                        ],
                                        "from_residual",
                                        []
                                      |),
                                      [ M.read (| residual |) ]
                                    |)
                                  |)
                                |)
                              |)
                            |)));
                        fun γ =>
                          ltac:(M.monadic
                            (let γ0_0 :=
                              M.SubPointer.get_struct_tuple_field (|
                                γ,
                                "core::ops::control_flow::ControlFlow::Continue",
                                0
                              |) in
                            let val := M.copy (| γ0_0 |) in
                            val))
                      ]
                    |) in
                  let accounts :=
                    M.alloc (|
                      M.call_closure (|
                        M.get_associated_function (|
                          Ty.apply
                            (Ty.path "slice")
                            [ Ty.path "solana_program::instruction::AccountMeta" ],
                          "into_vec",
                          [ Ty.path "alloc::alloc::Global" ]
                        |),
                        [
                          (* Unsize *)
                          M.pointer_coercion
                            (M.read (|
                              M.call_closure (|
                                M.get_associated_function (|
                                  Ty.apply
                                    (Ty.path "alloc::boxed::Box")
                                    [
                                      Ty.apply
                                        (Ty.path "array")
                                        [ Ty.path "solana_program::instruction::AccountMeta" ];
                                      Ty.path "alloc::alloc::Global"
                                    ],
                                  "new",
                                  []
                                |),
                                [
                                  M.alloc (|
                                    Value.Array
                                      [
                                        M.call_closure (|
                                          M.get_associated_function (|
                                            Ty.path "solana_program::instruction::AccountMeta",
                                            "new",
                                            []
                                          |),
                                          [
                                            M.read (| M.read (| source_token_account |) |);
                                            Value.Bool false
                                          ]
                                        |);
                                        M.call_closure (|
                                          M.get_associated_function (|
                                            Ty.path "solana_program::instruction::AccountMeta",
                                            "new_readonly",
                                            []
                                          |),
                                          [ M.read (| M.read (| mint |) |); Value.Bool false ]
                                        |);
                                        M.call_closure (|
                                          M.get_associated_function (|
                                            Ty.path "solana_program::instruction::AccountMeta",
                                            "new",
                                            []
                                          |),
                                          [
                                            M.read (| M.read (| destination_token_account |) |);
                                            Value.Bool false
                                          ]
                                        |)
                                      ]
                                  |)
                                ]
                              |)
                            |))
                        ]
                      |)
                    |) in
                  let proof_instruction_offset :=
                    M.copy (|
                      M.match_operator (|
                        proof_data_location,
                        [
                          fun γ =>
                            ltac:(M.monadic
                              (let γ0_0 :=
                                M.SubPointer.get_struct_tuple_field (|
                                  γ,
                                  "spl_token_2022::proof::ProofLocation::InstructionOffset",
                                  0
                                |) in
                              let γ0_1 :=
                                M.SubPointer.get_struct_tuple_field (|
                                  γ,
                                  "spl_token_2022::proof::ProofLocation::InstructionOffset",
                                  1
                                |) in
                              let proof_instruction_offset := M.copy (| γ0_0 |) in
                              let _ :=
                                M.alloc (|
                                  M.call_closure (|
                                    M.get_associated_function (|
                                      Ty.apply
                                        (Ty.path "alloc::vec::Vec")
                                        [
                                          Ty.path "solana_program::instruction::AccountMeta";
                                          Ty.path "alloc::alloc::Global"
                                        ],
                                      "push",
                                      []
                                    |),
                                    [
                                      accounts;
                                      M.call_closure (|
                                        M.get_associated_function (|
                                          Ty.path "solana_program::instruction::AccountMeta",
                                          "new_readonly",
                                          []
                                        |),
                                        [
                                          M.call_closure (|
                                            M.get_function (|
                                              "solana_program::sysvar::instructions::id",
                                              []
                                            |),
                                            []
                                          |);
                                          Value.Bool false
                                        ]
                                      |)
                                    ]
                                  |)
                                |) in
                              M.alloc (|
                                M.call_closure (|
                                  M.get_trait_method (|
                                    "core::convert::Into",
                                    Ty.path "core::num::nonzero::NonZeroI8",
                                    [ Ty.path "i8" ],
                                    "into",
                                    []
                                  |),
                                  [ M.read (| proof_instruction_offset |) ]
                                |)
                              |)));
                          fun γ =>
                            ltac:(M.monadic
                              (let γ0_0 :=
                                M.SubPointer.get_struct_tuple_field (|
                                  γ,
                                  "spl_token_2022::proof::ProofLocation::ContextStateAccount",
                                  0
                                |) in
                              let context_state_account := M.copy (| γ0_0 |) in
                              let _ :=
                                M.alloc (|
                                  M.call_closure (|
                                    M.get_associated_function (|
                                      Ty.apply
                                        (Ty.path "alloc::vec::Vec")
                                        [
                                          Ty.path "solana_program::instruction::AccountMeta";
                                          Ty.path "alloc::alloc::Global"
                                        ],
                                      "push",
                                      []
                                    |),
                                    [
                                      accounts;
                                      M.call_closure (|
                                        M.get_associated_function (|
                                          Ty.path "solana_program::instruction::AccountMeta",
                                          "new_readonly",
                                          []
                                        |),
                                        [
                                          M.read (| M.read (| context_state_account |) |);
                                          Value.Bool false
                                        ]
                                      |)
                                    ]
                                  |)
                                |) in
                              M.alloc (| Value.Integer 0 |)))
                        ]
                      |)
                    |) in
                  let _ :=
                    M.alloc (|
                      M.call_closure (|
                        M.get_associated_function (|
                          Ty.apply
                            (Ty.path "alloc::vec::Vec")
                            [
                              Ty.path "solana_program::instruction::AccountMeta";
                              Ty.path "alloc::alloc::Global"
                            ],
                          "push",
                          []
                        |),
                        [
                          accounts;
                          M.call_closure (|
                            M.get_associated_function (|
                              Ty.path "solana_program::instruction::AccountMeta",
                              "new_readonly",
                              []
                            |),
                            [
                              M.read (| M.read (| authority |) |);
                              M.call_closure (|
                                M.get_associated_function (|
                                  Ty.apply
                                    (Ty.path "slice")
                                    [
                                      Ty.apply
                                        (Ty.path "&")
                                        [ Ty.path "solana_program::pubkey::Pubkey" ]
                                    ],
                                  "is_empty",
                                  []
                                |),
                                [ M.read (| multisig_signers |) ]
                              |)
                            ]
                          |)
                        ]
                      |)
                    |) in
                  let _ :=
                    M.use
                      (M.match_operator (|
                        M.alloc (|
                          M.call_closure (|
                            M.get_trait_method (|
                              "core::iter::traits::collect::IntoIterator",
                              Ty.apply
                                (Ty.path "core::slice::iter::Iter")
                                [
                                  Ty.apply
                                    (Ty.path "&")
                                    [ Ty.path "solana_program::pubkey::Pubkey" ]
                                ],
                              [],
                              "into_iter",
                              []
                            |),
                            [
                              M.call_closure (|
                                M.get_associated_function (|
                                  Ty.apply
                                    (Ty.path "slice")
                                    [
                                      Ty.apply
                                        (Ty.path "&")
                                        [ Ty.path "solana_program::pubkey::Pubkey" ]
                                    ],
                                  "iter",
                                  []
                                |),
                                [ M.read (| multisig_signers |) ]
                              |)
                            ]
                          |)
                        |),
                        [
                          fun γ =>
                            ltac:(M.monadic
                              (let iter := M.copy (| γ |) in
                              M.loop (|
                                ltac:(M.monadic
                                  (let _ :=
                                    M.match_operator (|
                                      M.alloc (|
                                        M.call_closure (|
                                          M.get_trait_method (|
                                            "core::iter::traits::iterator::Iterator",
                                            Ty.apply
                                              (Ty.path "core::slice::iter::Iter")
                                              [
                                                Ty.apply
                                                  (Ty.path "&")
                                                  [ Ty.path "solana_program::pubkey::Pubkey" ]
                                              ],
                                            [],
                                            "next",
                                            []
                                          |),
                                          [ iter ]
                                        |)
                                      |),
                                      [
                                        fun γ =>
                                          ltac:(M.monadic
                                            (M.alloc (|
                                              M.never_to_any (| M.read (| M.break (||) |) |)
                                            |)));
                                        fun γ =>
                                          ltac:(M.monadic
                                            (let γ0_0 :=
                                              M.SubPointer.get_struct_tuple_field (|
                                                γ,
                                                "core::option::Option::Some",
                                                0
                                              |) in
                                            let multisig_signer := M.copy (| γ0_0 |) in
                                            let _ :=
                                              M.alloc (|
                                                M.call_closure (|
                                                  M.get_associated_function (|
                                                    Ty.apply
                                                      (Ty.path "alloc::vec::Vec")
                                                      [
                                                        Ty.path
                                                          "solana_program::instruction::AccountMeta";
                                                        Ty.path "alloc::alloc::Global"
                                                      ],
                                                    "push",
                                                    []
                                                  |),
                                                  [
                                                    accounts;
                                                    M.call_closure (|
                                                      M.get_associated_function (|
                                                        Ty.path
                                                          "solana_program::instruction::AccountMeta",
                                                        "new_readonly",
                                                        []
                                                      |),
                                                      [
                                                        M.read (|
                                                          M.read (| M.read (| multisig_signer |) |)
                                                        |);
                                                        Value.Bool true
                                                      ]
                                                    |)
                                                  ]
                                                |)
                                              |) in
                                            M.alloc (| Value.Tuple [] |)))
                                      ]
                                    |) in
                                  M.alloc (| Value.Tuple [] |)))
                              |)))
                        ]
                      |)) in
                  M.alloc (|
                    Value.StructTuple
                      "core::result::Result::Ok"
                      [
                        M.call_closure (|
                          M.get_function (|
                            "spl_token_2022::instruction::encode_instruction",
                            [
                              Ty.path
                                "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction";
                              Ty.path
                                "spl_token_2022::extension::confidential_transfer::instruction::TransferInstructionData"
                            ]
                          |),
                          [
                            M.read (| token_program_id |);
                            M.read (| accounts |);
                            Value.StructTuple
                              "spl_token_2022::instruction::TokenInstruction::ConfidentialTransferExtension"
                              [];
                            Value.StructTuple
                              "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction::Transfer"
                              [];
                            M.alloc (|
                              Value.StructRecord
                                "spl_token_2022::extension::confidential_transfer::instruction::TransferInstructionData"
                                [
                                  ("new_source_decryptable_available_balance",
                                    M.read (| new_source_decryptable_available_balance |));
                                  ("proof_instruction_offset",
                                    M.read (| proof_instruction_offset |))
                                ]
                            |)
                          ]
                        |)
                      ]
                  |)
                |)))
            |)))
        | _, _ => M.impossible
        end.
      
      (*
      pub fn transfer_with_fee(
          token_program_id: &Pubkey,
          source_token_account: &Pubkey,
          mint: &Pubkey,
          destination_token_account: &Pubkey,
          new_source_decryptable_available_balance: AeCiphertext,
          authority: &Pubkey,
          multisig_signers: &[&Pubkey],
          proof_data_location: ProofLocation<TransferWithFeeData>,
      ) -> Result<Vec<Instruction>, ProgramError> {
          let mut instructions = vec![inner_transfer_with_fee(
              token_program_id,
              source_token_account,
              destination_token_account,
              mint,
              new_source_decryptable_available_balance.into(),
              authority,
              multisig_signers,
              proof_data_location,
          )?];
      
          if let ProofLocation::InstructionOffset(proof_instruction_offset, proof_data) =
              proof_data_location
          {
              // This constructor appends the proof instruction right after the
              // `TransferWithFee` instruction. This means that the proof instruction
              // offset must be always be 1. To use an arbitrary proof instruction
              // offset, use the `inner_transfer_with_fee` constructor.
              let proof_instruction_offset: i8 = proof_instruction_offset.into();
              if proof_instruction_offset != 1 {
                  return Err(TokenError::InvalidProofInstructionOffset.into());
              }
              instructions.push(verify_transfer_with_fee(None, proof_data));
          };
      
          Ok(instructions)
      }
      *)
      Definition transfer_with_fee (τ : list Ty.t) (α : list Value.t) : M :=
        match τ, α with
        | [],
            [
              token_program_id;
              source_token_account;
              mint;
              destination_token_account;
              new_source_decryptable_available_balance;
              authority;
              multisig_signers;
              proof_data_location
            ] =>
          ltac:(M.monadic
            (let token_program_id := M.alloc (| token_program_id |) in
            let source_token_account := M.alloc (| source_token_account |) in
            let mint := M.alloc (| mint |) in
            let destination_token_account := M.alloc (| destination_token_account |) in
            let new_source_decryptable_available_balance :=
              M.alloc (| new_source_decryptable_available_balance |) in
            let authority := M.alloc (| authority |) in
            let multisig_signers := M.alloc (| multisig_signers |) in
            let proof_data_location := M.alloc (| proof_data_location |) in
            M.catch_return (|
              ltac:(M.monadic
                (M.read (|
                  let instructions :=
                    M.alloc (|
                      M.call_closure (|
                        M.get_associated_function (|
                          Ty.apply
                            (Ty.path "slice")
                            [ Ty.path "solana_program::instruction::Instruction" ],
                          "into_vec",
                          [ Ty.path "alloc::alloc::Global" ]
                        |),
                        [
                          (* Unsize *)
                          M.pointer_coercion
                            (M.read (|
                              M.call_closure (|
                                M.get_associated_function (|
                                  Ty.apply
                                    (Ty.path "alloc::boxed::Box")
                                    [
                                      Ty.apply
                                        (Ty.path "array")
                                        [ Ty.path "solana_program::instruction::Instruction" ];
                                      Ty.path "alloc::alloc::Global"
                                    ],
                                  "new",
                                  []
                                |),
                                [
                                  M.alloc (|
                                    Value.Array
                                      [
                                        M.read (|
                                          M.match_operator (|
                                            M.alloc (|
                                              M.call_closure (|
                                                M.get_trait_method (|
                                                  "core::ops::try_trait::Try",
                                                  Ty.apply
                                                    (Ty.path "core::result::Result")
                                                    [
                                                      Ty.path
                                                        "solana_program::instruction::Instruction";
                                                      Ty.path
                                                        "solana_program::program_error::ProgramError"
                                                    ],
                                                  [],
                                                  "branch",
                                                  []
                                                |),
                                                [
                                                  M.call_closure (|
                                                    M.get_function (|
                                                      "spl_token_2022::extension::confidential_transfer::instruction::inner_transfer_with_fee",
                                                      []
                                                    |),
                                                    [
                                                      M.read (| token_program_id |);
                                                      M.read (| source_token_account |);
                                                      M.read (| destination_token_account |);
                                                      M.read (| mint |);
                                                      M.call_closure (|
                                                        M.get_trait_method (|
                                                          "core::convert::Into",
                                                          Ty.path
                                                            "solana_zk_token_sdk::encryption::auth_encryption::AeCiphertext",
                                                          [
                                                            Ty.path
                                                              "solana_zk_token_sdk::zk_token_elgamal::pod::auth_encryption::AeCiphertext"
                                                          ],
                                                          "into",
                                                          []
                                                        |),
                                                        [
                                                          M.read (|
                                                            new_source_decryptable_available_balance
                                                          |)
                                                        ]
                                                      |);
                                                      M.read (| authority |);
                                                      M.read (| multisig_signers |);
                                                      M.read (| proof_data_location |)
                                                    ]
                                                  |)
                                                ]
                                              |)
                                            |),
                                            [
                                              fun γ =>
                                                ltac:(M.monadic
                                                  (let γ0_0 :=
                                                    M.SubPointer.get_struct_tuple_field (|
                                                      γ,
                                                      "core::ops::control_flow::ControlFlow::Break",
                                                      0
                                                    |) in
                                                  let residual := M.copy (| γ0_0 |) in
                                                  M.alloc (|
                                                    M.never_to_any (|
                                                      M.read (|
                                                        M.return_ (|
                                                          M.call_closure (|
                                                            M.get_trait_method (|
                                                              "core::ops::try_trait::FromResidual",
                                                              Ty.apply
                                                                (Ty.path "core::result::Result")
                                                                [
                                                                  Ty.apply
                                                                    (Ty.path "alloc::vec::Vec")
                                                                    [
                                                                      Ty.path
                                                                        "solana_program::instruction::Instruction";
                                                                      Ty.path "alloc::alloc::Global"
                                                                    ];
                                                                  Ty.path
                                                                    "solana_program::program_error::ProgramError"
                                                                ],
                                                              [
                                                                Ty.apply
                                                                  (Ty.path "core::result::Result")
                                                                  [
                                                                    Ty.path
                                                                      "core::convert::Infallible";
                                                                    Ty.path
                                                                      "solana_program::program_error::ProgramError"
                                                                  ]
                                                              ],
                                                              "from_residual",
                                                              []
                                                            |),
                                                            [ M.read (| residual |) ]
                                                          |)
                                                        |)
                                                      |)
                                                    |)
                                                  |)));
                                              fun γ =>
                                                ltac:(M.monadic
                                                  (let γ0_0 :=
                                                    M.SubPointer.get_struct_tuple_field (|
                                                      γ,
                                                      "core::ops::control_flow::ControlFlow::Continue",
                                                      0
                                                    |) in
                                                  let val := M.copy (| γ0_0 |) in
                                                  val))
                                            ]
                                          |)
                                        |)
                                      ]
                                  |)
                                ]
                              |)
                            |))
                        ]
                      |)
                    |) in
                  let _ :=
                    M.match_operator (|
                      M.alloc (| Value.Tuple [] |),
                      [
                        fun γ =>
                          ltac:(M.monadic
                            (let γ := proof_data_location in
                            let γ0_0 :=
                              M.SubPointer.get_struct_tuple_field (|
                                γ,
                                "spl_token_2022::proof::ProofLocation::InstructionOffset",
                                0
                              |) in
                            let γ0_1 :=
                              M.SubPointer.get_struct_tuple_field (|
                                γ,
                                "spl_token_2022::proof::ProofLocation::InstructionOffset",
                                1
                              |) in
                            let proof_instruction_offset := M.copy (| γ0_0 |) in
                            let proof_data := M.copy (| γ0_1 |) in
                            let proof_instruction_offset :=
                              M.alloc (|
                                M.call_closure (|
                                  M.get_trait_method (|
                                    "core::convert::Into",
                                    Ty.path "core::num::nonzero::NonZeroI8",
                                    [ Ty.path "i8" ],
                                    "into",
                                    []
                                  |),
                                  [ M.read (| proof_instruction_offset |) ]
                                |)
                              |) in
                            let _ :=
                              M.match_operator (|
                                M.alloc (| Value.Tuple [] |),
                                [
                                  fun γ =>
                                    ltac:(M.monadic
                                      (let γ :=
                                        M.use
                                          (M.alloc (|
                                            BinOp.Pure.ne
                                              (M.read (| proof_instruction_offset |))
                                              (Value.Integer 1)
                                          |)) in
                                      let _ :=
                                        M.is_constant_or_break_match (|
                                          M.read (| γ |),
                                          Value.Bool true
                                        |) in
                                      M.alloc (|
                                        M.never_to_any (|
                                          M.read (|
                                            M.return_ (|
                                              Value.StructTuple
                                                "core::result::Result::Err"
                                                [
                                                  M.call_closure (|
                                                    M.get_trait_method (|
                                                      "core::convert::Into",
                                                      Ty.path "spl_token_2022::error::TokenError",
                                                      [
                                                        Ty.path
                                                          "solana_program::program_error::ProgramError"
                                                      ],
                                                      "into",
                                                      []
                                                    |),
                                                    [
                                                      Value.StructTuple
                                                        "spl_token_2022::error::TokenError::InvalidProofInstructionOffset"
                                                        []
                                                    ]
                                                  |)
                                                ]
                                            |)
                                          |)
                                        |)
                                      |)));
                                  fun γ => ltac:(M.monadic (M.alloc (| Value.Tuple [] |)))
                                ]
                              |) in
                            let _ :=
                              M.alloc (|
                                M.call_closure (|
                                  M.get_associated_function (|
                                    Ty.apply
                                      (Ty.path "alloc::vec::Vec")
                                      [
                                        Ty.path "solana_program::instruction::Instruction";
                                        Ty.path "alloc::alloc::Global"
                                      ],
                                    "push",
                                    []
                                  |),
                                  [
                                    instructions;
                                    M.call_closure (|
                                      M.get_function (|
                                        "solana_zk_token_sdk::zk_token_proof_instruction::verify_transfer_with_fee",
                                        []
                                      |),
                                      [
                                        Value.StructTuple "core::option::Option::None" [];
                                        M.read (| proof_data |)
                                      ]
                                    |)
                                  ]
                                |)
                              |) in
                            M.alloc (| Value.Tuple [] |)));
                        fun γ => ltac:(M.monadic (M.alloc (| Value.Tuple [] |)))
                      ]
                    |) in
                  M.alloc (|
                    Value.StructTuple "core::result::Result::Ok" [ M.read (| instructions |) ]
                  |)
                |)))
            |)))
        | _, _ => M.impossible
        end.
      
      (*
      pub fn inner_apply_pending_balance(
          token_program_id: &Pubkey,
          token_account: &Pubkey,
          expected_pending_balance_credit_counter: u64,
          new_decryptable_available_balance: DecryptableBalance,
          authority: &Pubkey,
          multisig_signers: &[&Pubkey],
      ) -> Result<Instruction, ProgramError> {
          check_program_account(token_program_id)?;
          let mut accounts = vec![
              AccountMeta::new( *token_account, false),
              AccountMeta::new_readonly( *authority, multisig_signers.is_empty()),
          ];
      
          for multisig_signer in multisig_signers.iter() {
              accounts.push(AccountMeta::new_readonly( **multisig_signer, true));
          }
      
          Ok(encode_instruction(
              token_program_id,
              accounts,
              TokenInstruction::ConfidentialTransferExtension,
              ConfidentialTransferInstruction::ApplyPendingBalance,
              &ApplyPendingBalanceData {
                  expected_pending_balance_credit_counter: expected_pending_balance_credit_counter.into(),
                  new_decryptable_available_balance,
              },
          ))
      }
      *)
      Definition inner_apply_pending_balance (τ : list Ty.t) (α : list Value.t) : M :=
        match τ, α with
        | [],
            [
              token_program_id;
              token_account;
              expected_pending_balance_credit_counter;
              new_decryptable_available_balance;
              authority;
              multisig_signers
            ] =>
          ltac:(M.monadic
            (let token_program_id := M.alloc (| token_program_id |) in
            let token_account := M.alloc (| token_account |) in
            let expected_pending_balance_credit_counter :=
              M.alloc (| expected_pending_balance_credit_counter |) in
            let new_decryptable_available_balance :=
              M.alloc (| new_decryptable_available_balance |) in
            let authority := M.alloc (| authority |) in
            let multisig_signers := M.alloc (| multisig_signers |) in
            M.catch_return (|
              ltac:(M.monadic
                (M.read (|
                  let _ :=
                    M.match_operator (|
                      M.alloc (|
                        M.call_closure (|
                          M.get_trait_method (|
                            "core::ops::try_trait::Try",
                            Ty.apply
                              (Ty.path "core::result::Result")
                              [ Ty.tuple []; Ty.path "solana_program::program_error::ProgramError"
                              ],
                            [],
                            "branch",
                            []
                          |),
                          [
                            M.call_closure (|
                              M.get_function (| "spl_token_2022::check_program_account", [] |),
                              [ M.read (| token_program_id |) ]
                            |)
                          ]
                        |)
                      |),
                      [
                        fun γ =>
                          ltac:(M.monadic
                            (let γ0_0 :=
                              M.SubPointer.get_struct_tuple_field (|
                                γ,
                                "core::ops::control_flow::ControlFlow::Break",
                                0
                              |) in
                            let residual := M.copy (| γ0_0 |) in
                            M.alloc (|
                              M.never_to_any (|
                                M.read (|
                                  M.return_ (|
                                    M.call_closure (|
                                      M.get_trait_method (|
                                        "core::ops::try_trait::FromResidual",
                                        Ty.apply
                                          (Ty.path "core::result::Result")
                                          [
                                            Ty.path "solana_program::instruction::Instruction";
                                            Ty.path "solana_program::program_error::ProgramError"
                                          ],
                                        [
                                          Ty.apply
                                            (Ty.path "core::result::Result")
                                            [
                                              Ty.path "core::convert::Infallible";
                                              Ty.path "solana_program::program_error::ProgramError"
                                            ]
                                        ],
                                        "from_residual",
                                        []
                                      |),
                                      [ M.read (| residual |) ]
                                    |)
                                  |)
                                |)
                              |)
                            |)));
                        fun γ =>
                          ltac:(M.monadic
                            (let γ0_0 :=
                              M.SubPointer.get_struct_tuple_field (|
                                γ,
                                "core::ops::control_flow::ControlFlow::Continue",
                                0
                              |) in
                            let val := M.copy (| γ0_0 |) in
                            val))
                      ]
                    |) in
                  let accounts :=
                    M.alloc (|
                      M.call_closure (|
                        M.get_associated_function (|
                          Ty.apply
                            (Ty.path "slice")
                            [ Ty.path "solana_program::instruction::AccountMeta" ],
                          "into_vec",
                          [ Ty.path "alloc::alloc::Global" ]
                        |),
                        [
                          (* Unsize *)
                          M.pointer_coercion
                            (M.read (|
                              M.call_closure (|
                                M.get_associated_function (|
                                  Ty.apply
                                    (Ty.path "alloc::boxed::Box")
                                    [
                                      Ty.apply
                                        (Ty.path "array")
                                        [ Ty.path "solana_program::instruction::AccountMeta" ];
                                      Ty.path "alloc::alloc::Global"
                                    ],
                                  "new",
                                  []
                                |),
                                [
                                  M.alloc (|
                                    Value.Array
                                      [
                                        M.call_closure (|
                                          M.get_associated_function (|
                                            Ty.path "solana_program::instruction::AccountMeta",
                                            "new",
                                            []
                                          |),
                                          [
                                            M.read (| M.read (| token_account |) |);
                                            Value.Bool false
                                          ]
                                        |);
                                        M.call_closure (|
                                          M.get_associated_function (|
                                            Ty.path "solana_program::instruction::AccountMeta",
                                            "new_readonly",
                                            []
                                          |),
                                          [
                                            M.read (| M.read (| authority |) |);
                                            M.call_closure (|
                                              M.get_associated_function (|
                                                Ty.apply
                                                  (Ty.path "slice")
                                                  [
                                                    Ty.apply
                                                      (Ty.path "&")
                                                      [ Ty.path "solana_program::pubkey::Pubkey" ]
                                                  ],
                                                "is_empty",
                                                []
                                              |),
                                              [ M.read (| multisig_signers |) ]
                                            |)
                                          ]
                                        |)
                                      ]
                                  |)
                                ]
                              |)
                            |))
                        ]
                      |)
                    |) in
                  let _ :=
                    M.use
                      (M.match_operator (|
                        M.alloc (|
                          M.call_closure (|
                            M.get_trait_method (|
                              "core::iter::traits::collect::IntoIterator",
                              Ty.apply
                                (Ty.path "core::slice::iter::Iter")
                                [
                                  Ty.apply
                                    (Ty.path "&")
                                    [ Ty.path "solana_program::pubkey::Pubkey" ]
                                ],
                              [],
                              "into_iter",
                              []
                            |),
                            [
                              M.call_closure (|
                                M.get_associated_function (|
                                  Ty.apply
                                    (Ty.path "slice")
                                    [
                                      Ty.apply
                                        (Ty.path "&")
                                        [ Ty.path "solana_program::pubkey::Pubkey" ]
                                    ],
                                  "iter",
                                  []
                                |),
                                [ M.read (| multisig_signers |) ]
                              |)
                            ]
                          |)
                        |),
                        [
                          fun γ =>
                            ltac:(M.monadic
                              (let iter := M.copy (| γ |) in
                              M.loop (|
                                ltac:(M.monadic
                                  (let _ :=
                                    M.match_operator (|
                                      M.alloc (|
                                        M.call_closure (|
                                          M.get_trait_method (|
                                            "core::iter::traits::iterator::Iterator",
                                            Ty.apply
                                              (Ty.path "core::slice::iter::Iter")
                                              [
                                                Ty.apply
                                                  (Ty.path "&")
                                                  [ Ty.path "solana_program::pubkey::Pubkey" ]
                                              ],
                                            [],
                                            "next",
                                            []
                                          |),
                                          [ iter ]
                                        |)
                                      |),
                                      [
                                        fun γ =>
                                          ltac:(M.monadic
                                            (M.alloc (|
                                              M.never_to_any (| M.read (| M.break (||) |) |)
                                            |)));
                                        fun γ =>
                                          ltac:(M.monadic
                                            (let γ0_0 :=
                                              M.SubPointer.get_struct_tuple_field (|
                                                γ,
                                                "core::option::Option::Some",
                                                0
                                              |) in
                                            let multisig_signer := M.copy (| γ0_0 |) in
                                            let _ :=
                                              M.alloc (|
                                                M.call_closure (|
                                                  M.get_associated_function (|
                                                    Ty.apply
                                                      (Ty.path "alloc::vec::Vec")
                                                      [
                                                        Ty.path
                                                          "solana_program::instruction::AccountMeta";
                                                        Ty.path "alloc::alloc::Global"
                                                      ],
                                                    "push",
                                                    []
                                                  |),
                                                  [
                                                    accounts;
                                                    M.call_closure (|
                                                      M.get_associated_function (|
                                                        Ty.path
                                                          "solana_program::instruction::AccountMeta",
                                                        "new_readonly",
                                                        []
                                                      |),
                                                      [
                                                        M.read (|
                                                          M.read (| M.read (| multisig_signer |) |)
                                                        |);
                                                        Value.Bool true
                                                      ]
                                                    |)
                                                  ]
                                                |)
                                              |) in
                                            M.alloc (| Value.Tuple [] |)))
                                      ]
                                    |) in
                                  M.alloc (| Value.Tuple [] |)))
                              |)))
                        ]
                      |)) in
                  M.alloc (|
                    Value.StructTuple
                      "core::result::Result::Ok"
                      [
                        M.call_closure (|
                          M.get_function (|
                            "spl_token_2022::instruction::encode_instruction",
                            [
                              Ty.path
                                "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction";
                              Ty.path
                                "spl_token_2022::extension::confidential_transfer::instruction::ApplyPendingBalanceData"
                            ]
                          |),
                          [
                            M.read (| token_program_id |);
                            M.read (| accounts |);
                            Value.StructTuple
                              "spl_token_2022::instruction::TokenInstruction::ConfidentialTransferExtension"
                              [];
                            Value.StructTuple
                              "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction::ApplyPendingBalance"
                              [];
                            M.alloc (|
                              Value.StructRecord
                                "spl_token_2022::extension::confidential_transfer::instruction::ApplyPendingBalanceData"
                                [
                                  ("expected_pending_balance_credit_counter",
                                    M.call_closure (|
                                      M.get_trait_method (|
                                        "core::convert::Into",
                                        Ty.path "u64",
                                        [ Ty.path "spl_pod::primitives::PodU64" ],
                                        "into",
                                        []
                                      |),
                                      [ M.read (| expected_pending_balance_credit_counter |) ]
                                    |));
                                  ("new_decryptable_available_balance",
                                    M.read (| new_decryptable_available_balance |))
                                ]
                            |)
                          ]
                        |)
                      ]
                  |)
                |)))
            |)))
        | _, _ => M.impossible
        end.
      
      (*
      pub fn apply_pending_balance(
          token_program_id: &Pubkey,
          token_account: &Pubkey,
          pending_balance_instructions: u64,
          new_decryptable_available_balance: AeCiphertext,
          authority: &Pubkey,
          multisig_signers: &[&Pubkey],
      ) -> Result<Instruction, ProgramError> {
          inner_apply_pending_balance(
              token_program_id,
              token_account,
              pending_balance_instructions,
              new_decryptable_available_balance.into(),
              authority,
              multisig_signers,
          ) // calls check_program_account
      }
      *)
      Definition apply_pending_balance (τ : list Ty.t) (α : list Value.t) : M :=
        match τ, α with
        | [],
            [
              token_program_id;
              token_account;
              pending_balance_instructions;
              new_decryptable_available_balance;
              authority;
              multisig_signers
            ] =>
          ltac:(M.monadic
            (let token_program_id := M.alloc (| token_program_id |) in
            let token_account := M.alloc (| token_account |) in
            let pending_balance_instructions := M.alloc (| pending_balance_instructions |) in
            let new_decryptable_available_balance :=
              M.alloc (| new_decryptable_available_balance |) in
            let authority := M.alloc (| authority |) in
            let multisig_signers := M.alloc (| multisig_signers |) in
            M.call_closure (|
              M.get_function (|
                "spl_token_2022::extension::confidential_transfer::instruction::inner_apply_pending_balance",
                []
              |),
              [
                M.read (| token_program_id |);
                M.read (| token_account |);
                M.read (| pending_balance_instructions |);
                M.call_closure (|
                  M.get_trait_method (|
                    "core::convert::Into",
                    Ty.path "solana_zk_token_sdk::encryption::auth_encryption::AeCiphertext",
                    [
                      Ty.path
                        "solana_zk_token_sdk::zk_token_elgamal::pod::auth_encryption::AeCiphertext"
                    ],
                    "into",
                    []
                  |),
                  [ M.read (| new_decryptable_available_balance |) ]
                |);
                M.read (| authority |);
                M.read (| multisig_signers |)
              ]
            |)))
        | _, _ => M.impossible
        end.
      
      (*
      fn enable_or_disable_balance_credits(
          instruction: ConfidentialTransferInstruction,
          token_program_id: &Pubkey,
          token_account: &Pubkey,
          authority: &Pubkey,
          multisig_signers: &[&Pubkey],
      ) -> Result<Instruction, ProgramError> {
          check_program_account(token_program_id)?;
          let mut accounts = vec![
              AccountMeta::new( *token_account, false),
              AccountMeta::new_readonly( *authority, multisig_signers.is_empty()),
          ];
      
          for multisig_signer in multisig_signers.iter() {
              accounts.push(AccountMeta::new_readonly( **multisig_signer, true));
          }
      
          Ok(encode_instruction(
              token_program_id,
              accounts,
              TokenInstruction::ConfidentialTransferExtension,
              instruction,
              &(),
          ))
      }
      *)
      Definition enable_or_disable_balance_credits (τ : list Ty.t) (α : list Value.t) : M :=
        match τ, α with
        | [], [ instruction; token_program_id; token_account; authority; multisig_signers ] =>
          ltac:(M.monadic
            (let instruction := M.alloc (| instruction |) in
            let token_program_id := M.alloc (| token_program_id |) in
            let token_account := M.alloc (| token_account |) in
            let authority := M.alloc (| authority |) in
            let multisig_signers := M.alloc (| multisig_signers |) in
            M.catch_return (|
              ltac:(M.monadic
                (M.read (|
                  let _ :=
                    M.match_operator (|
                      M.alloc (|
                        M.call_closure (|
                          M.get_trait_method (|
                            "core::ops::try_trait::Try",
                            Ty.apply
                              (Ty.path "core::result::Result")
                              [ Ty.tuple []; Ty.path "solana_program::program_error::ProgramError"
                              ],
                            [],
                            "branch",
                            []
                          |),
                          [
                            M.call_closure (|
                              M.get_function (| "spl_token_2022::check_program_account", [] |),
                              [ M.read (| token_program_id |) ]
                            |)
                          ]
                        |)
                      |),
                      [
                        fun γ =>
                          ltac:(M.monadic
                            (let γ0_0 :=
                              M.SubPointer.get_struct_tuple_field (|
                                γ,
                                "core::ops::control_flow::ControlFlow::Break",
                                0
                              |) in
                            let residual := M.copy (| γ0_0 |) in
                            M.alloc (|
                              M.never_to_any (|
                                M.read (|
                                  M.return_ (|
                                    M.call_closure (|
                                      M.get_trait_method (|
                                        "core::ops::try_trait::FromResidual",
                                        Ty.apply
                                          (Ty.path "core::result::Result")
                                          [
                                            Ty.path "solana_program::instruction::Instruction";
                                            Ty.path "solana_program::program_error::ProgramError"
                                          ],
                                        [
                                          Ty.apply
                                            (Ty.path "core::result::Result")
                                            [
                                              Ty.path "core::convert::Infallible";
                                              Ty.path "solana_program::program_error::ProgramError"
                                            ]
                                        ],
                                        "from_residual",
                                        []
                                      |),
                                      [ M.read (| residual |) ]
                                    |)
                                  |)
                                |)
                              |)
                            |)));
                        fun γ =>
                          ltac:(M.monadic
                            (let γ0_0 :=
                              M.SubPointer.get_struct_tuple_field (|
                                γ,
                                "core::ops::control_flow::ControlFlow::Continue",
                                0
                              |) in
                            let val := M.copy (| γ0_0 |) in
                            val))
                      ]
                    |) in
                  let accounts :=
                    M.alloc (|
                      M.call_closure (|
                        M.get_associated_function (|
                          Ty.apply
                            (Ty.path "slice")
                            [ Ty.path "solana_program::instruction::AccountMeta" ],
                          "into_vec",
                          [ Ty.path "alloc::alloc::Global" ]
                        |),
                        [
                          (* Unsize *)
                          M.pointer_coercion
                            (M.read (|
                              M.call_closure (|
                                M.get_associated_function (|
                                  Ty.apply
                                    (Ty.path "alloc::boxed::Box")
                                    [
                                      Ty.apply
                                        (Ty.path "array")
                                        [ Ty.path "solana_program::instruction::AccountMeta" ];
                                      Ty.path "alloc::alloc::Global"
                                    ],
                                  "new",
                                  []
                                |),
                                [
                                  M.alloc (|
                                    Value.Array
                                      [
                                        M.call_closure (|
                                          M.get_associated_function (|
                                            Ty.path "solana_program::instruction::AccountMeta",
                                            "new",
                                            []
                                          |),
                                          [
                                            M.read (| M.read (| token_account |) |);
                                            Value.Bool false
                                          ]
                                        |);
                                        M.call_closure (|
                                          M.get_associated_function (|
                                            Ty.path "solana_program::instruction::AccountMeta",
                                            "new_readonly",
                                            []
                                          |),
                                          [
                                            M.read (| M.read (| authority |) |);
                                            M.call_closure (|
                                              M.get_associated_function (|
                                                Ty.apply
                                                  (Ty.path "slice")
                                                  [
                                                    Ty.apply
                                                      (Ty.path "&")
                                                      [ Ty.path "solana_program::pubkey::Pubkey" ]
                                                  ],
                                                "is_empty",
                                                []
                                              |),
                                              [ M.read (| multisig_signers |) ]
                                            |)
                                          ]
                                        |)
                                      ]
                                  |)
                                ]
                              |)
                            |))
                        ]
                      |)
                    |) in
                  let _ :=
                    M.use
                      (M.match_operator (|
                        M.alloc (|
                          M.call_closure (|
                            M.get_trait_method (|
                              "core::iter::traits::collect::IntoIterator",
                              Ty.apply
                                (Ty.path "core::slice::iter::Iter")
                                [
                                  Ty.apply
                                    (Ty.path "&")
                                    [ Ty.path "solana_program::pubkey::Pubkey" ]
                                ],
                              [],
                              "into_iter",
                              []
                            |),
                            [
                              M.call_closure (|
                                M.get_associated_function (|
                                  Ty.apply
                                    (Ty.path "slice")
                                    [
                                      Ty.apply
                                        (Ty.path "&")
                                        [ Ty.path "solana_program::pubkey::Pubkey" ]
                                    ],
                                  "iter",
                                  []
                                |),
                                [ M.read (| multisig_signers |) ]
                              |)
                            ]
                          |)
                        |),
                        [
                          fun γ =>
                            ltac:(M.monadic
                              (let iter := M.copy (| γ |) in
                              M.loop (|
                                ltac:(M.monadic
                                  (let _ :=
                                    M.match_operator (|
                                      M.alloc (|
                                        M.call_closure (|
                                          M.get_trait_method (|
                                            "core::iter::traits::iterator::Iterator",
                                            Ty.apply
                                              (Ty.path "core::slice::iter::Iter")
                                              [
                                                Ty.apply
                                                  (Ty.path "&")
                                                  [ Ty.path "solana_program::pubkey::Pubkey" ]
                                              ],
                                            [],
                                            "next",
                                            []
                                          |),
                                          [ iter ]
                                        |)
                                      |),
                                      [
                                        fun γ =>
                                          ltac:(M.monadic
                                            (M.alloc (|
                                              M.never_to_any (| M.read (| M.break (||) |) |)
                                            |)));
                                        fun γ =>
                                          ltac:(M.monadic
                                            (let γ0_0 :=
                                              M.SubPointer.get_struct_tuple_field (|
                                                γ,
                                                "core::option::Option::Some",
                                                0
                                              |) in
                                            let multisig_signer := M.copy (| γ0_0 |) in
                                            let _ :=
                                              M.alloc (|
                                                M.call_closure (|
                                                  M.get_associated_function (|
                                                    Ty.apply
                                                      (Ty.path "alloc::vec::Vec")
                                                      [
                                                        Ty.path
                                                          "solana_program::instruction::AccountMeta";
                                                        Ty.path "alloc::alloc::Global"
                                                      ],
                                                    "push",
                                                    []
                                                  |),
                                                  [
                                                    accounts;
                                                    M.call_closure (|
                                                      M.get_associated_function (|
                                                        Ty.path
                                                          "solana_program::instruction::AccountMeta",
                                                        "new_readonly",
                                                        []
                                                      |),
                                                      [
                                                        M.read (|
                                                          M.read (| M.read (| multisig_signer |) |)
                                                        |);
                                                        Value.Bool true
                                                      ]
                                                    |)
                                                  ]
                                                |)
                                              |) in
                                            M.alloc (| Value.Tuple [] |)))
                                      ]
                                    |) in
                                  M.alloc (| Value.Tuple [] |)))
                              |)))
                        ]
                      |)) in
                  M.alloc (|
                    Value.StructTuple
                      "core::result::Result::Ok"
                      [
                        M.call_closure (|
                          M.get_function (|
                            "spl_token_2022::instruction::encode_instruction",
                            [
                              Ty.path
                                "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction";
                              Ty.tuple []
                            ]
                          |),
                          [
                            M.read (| token_program_id |);
                            M.read (| accounts |);
                            Value.StructTuple
                              "spl_token_2022::instruction::TokenInstruction::ConfidentialTransferExtension"
                              [];
                            M.read (| instruction |);
                            M.alloc (| Value.Tuple [] |)
                          ]
                        |)
                      ]
                  |)
                |)))
            |)))
        | _, _ => M.impossible
        end.
      
      (*
      pub fn enable_confidential_credits(
          token_program_id: &Pubkey,
          token_account: &Pubkey,
          authority: &Pubkey,
          multisig_signers: &[&Pubkey],
      ) -> Result<Instruction, ProgramError> {
          enable_or_disable_balance_credits(
              ConfidentialTransferInstruction::EnableConfidentialCredits,
              token_program_id,
              token_account,
              authority,
              multisig_signers,
          )
      }
      *)
      Definition enable_confidential_credits (τ : list Ty.t) (α : list Value.t) : M :=
        match τ, α with
        | [], [ token_program_id; token_account; authority; multisig_signers ] =>
          ltac:(M.monadic
            (let token_program_id := M.alloc (| token_program_id |) in
            let token_account := M.alloc (| token_account |) in
            let authority := M.alloc (| authority |) in
            let multisig_signers := M.alloc (| multisig_signers |) in
            M.call_closure (|
              M.get_function (|
                "spl_token_2022::extension::confidential_transfer::instruction::enable_or_disable_balance_credits",
                []
              |),
              [
                Value.StructTuple
                  "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction::EnableConfidentialCredits"
                  [];
                M.read (| token_program_id |);
                M.read (| token_account |);
                M.read (| authority |);
                M.read (| multisig_signers |)
              ]
            |)))
        | _, _ => M.impossible
        end.
      
      (*
      pub fn disable_confidential_credits(
          token_program_id: &Pubkey,
          token_account: &Pubkey,
          authority: &Pubkey,
          multisig_signers: &[&Pubkey],
      ) -> Result<Instruction, ProgramError> {
          enable_or_disable_balance_credits(
              ConfidentialTransferInstruction::DisableConfidentialCredits,
              token_program_id,
              token_account,
              authority,
              multisig_signers,
          )
      }
      *)
      Definition disable_confidential_credits (τ : list Ty.t) (α : list Value.t) : M :=
        match τ, α with
        | [], [ token_program_id; token_account; authority; multisig_signers ] =>
          ltac:(M.monadic
            (let token_program_id := M.alloc (| token_program_id |) in
            let token_account := M.alloc (| token_account |) in
            let authority := M.alloc (| authority |) in
            let multisig_signers := M.alloc (| multisig_signers |) in
            M.call_closure (|
              M.get_function (|
                "spl_token_2022::extension::confidential_transfer::instruction::enable_or_disable_balance_credits",
                []
              |),
              [
                Value.StructTuple
                  "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction::DisableConfidentialCredits"
                  [];
                M.read (| token_program_id |);
                M.read (| token_account |);
                M.read (| authority |);
                M.read (| multisig_signers |)
              ]
            |)))
        | _, _ => M.impossible
        end.
      
      (*
      pub fn enable_non_confidential_credits(
          token_program_id: &Pubkey,
          token_account: &Pubkey,
          authority: &Pubkey,
          multisig_signers: &[&Pubkey],
      ) -> Result<Instruction, ProgramError> {
          enable_or_disable_balance_credits(
              ConfidentialTransferInstruction::EnableNonConfidentialCredits,
              token_program_id,
              token_account,
              authority,
              multisig_signers,
          )
      }
      *)
      Definition enable_non_confidential_credits (τ : list Ty.t) (α : list Value.t) : M :=
        match τ, α with
        | [], [ token_program_id; token_account; authority; multisig_signers ] =>
          ltac:(M.monadic
            (let token_program_id := M.alloc (| token_program_id |) in
            let token_account := M.alloc (| token_account |) in
            let authority := M.alloc (| authority |) in
            let multisig_signers := M.alloc (| multisig_signers |) in
            M.call_closure (|
              M.get_function (|
                "spl_token_2022::extension::confidential_transfer::instruction::enable_or_disable_balance_credits",
                []
              |),
              [
                Value.StructTuple
                  "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction::EnableNonConfidentialCredits"
                  [];
                M.read (| token_program_id |);
                M.read (| token_account |);
                M.read (| authority |);
                M.read (| multisig_signers |)
              ]
            |)))
        | _, _ => M.impossible
        end.
      
      (*
      pub fn disable_non_confidential_credits(
          token_program_id: &Pubkey,
          token_account: &Pubkey,
          authority: &Pubkey,
          multisig_signers: &[&Pubkey],
      ) -> Result<Instruction, ProgramError> {
          enable_or_disable_balance_credits(
              ConfidentialTransferInstruction::DisableNonConfidentialCredits,
              token_program_id,
              token_account,
              authority,
              multisig_signers,
          )
      }
      *)
      Definition disable_non_confidential_credits (τ : list Ty.t) (α : list Value.t) : M :=
        match τ, α with
        | [], [ token_program_id; token_account; authority; multisig_signers ] =>
          ltac:(M.monadic
            (let token_program_id := M.alloc (| token_program_id |) in
            let token_account := M.alloc (| token_account |) in
            let authority := M.alloc (| authority |) in
            let multisig_signers := M.alloc (| multisig_signers |) in
            M.call_closure (|
              M.get_function (|
                "spl_token_2022::extension::confidential_transfer::instruction::enable_or_disable_balance_credits",
                []
              |),
              [
                Value.StructTuple
                  "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction::DisableNonConfidentialCredits"
                  [];
                M.read (| token_program_id |);
                M.read (| token_account |);
                M.read (| authority |);
                M.read (| multisig_signers |)
              ]
            |)))
        | _, _ => M.impossible
        end.
      
      (*
      pub fn transfer_with_split_proofs(
          token_program_id: &Pubkey,
          source_token_account: &Pubkey,
          mint: &Pubkey,
          destination_token_account: &Pubkey,
          new_source_decryptable_available_balance: DecryptableBalance,
          source_account_authority: &Pubkey,
          context_accounts: TransferSplitContextStateAccounts,
          source_decrypt_handles: &SourceDecryptHandles,
      ) -> Result<Instruction, ProgramError> {
          check_program_account(token_program_id)?;
          let mut accounts = vec![
              AccountMeta::new( *source_token_account, false),
              AccountMeta::new_readonly( *mint, false),
              AccountMeta::new( *destination_token_account, false),
          ];
      
          let close_split_context_state_on_execution =
              if let Some(close_split_context_state_on_execution_accounts) =
                  context_accounts.close_split_context_state_accounts
              {
                  // If `close_split_context_state_accounts` is set, then all context state
                  // accounts must be `writable`.
                  accounts.push(AccountMeta::new( *context_accounts.equality_proof, false));
                  accounts.push(AccountMeta::new(
                      *context_accounts.ciphertext_validity_proof,
                      false,
                  ));
                  accounts.push(AccountMeta::new( *context_accounts.range_proof, false));
                  accounts.push(AccountMeta::new(
                      *close_split_context_state_on_execution_accounts.lamport_destination,
                      false,
                  ));
                  accounts.push(AccountMeta::new_readonly( *context_accounts.authority, true));
                  accounts.push(AccountMeta::new_readonly(
                      *close_split_context_state_on_execution_accounts.zk_token_proof_program,
                      false,
                  ));
                  accounts.push(AccountMeta::new_readonly( *source_account_authority, true));
                  true
              } else {
                  // If `close_split_context_state_accounts` is not set, then context state
                  // accounts can be read-only.
                  accounts.push(AccountMeta::new_readonly(
                      *context_accounts.equality_proof,
                      false,
                  ));
                  accounts.push(AccountMeta::new_readonly(
                      *context_accounts.ciphertext_validity_proof,
                      false,
                  ));
                  accounts.push(AccountMeta::new_readonly(
                      *context_accounts.range_proof,
                      false,
                  ));
                  accounts.push(AccountMeta::new_readonly( *source_account_authority, true));
      
                  false
              };
      
          Ok(encode_instruction(
              token_program_id,
              accounts,
              TokenInstruction::ConfidentialTransferExtension,
              ConfidentialTransferInstruction::TransferWithSplitProofs,
              &TransferWithSplitProofsInstructionData {
                  new_source_decryptable_available_balance,
                  no_op_on_uninitialized_split_context_state: context_accounts
                      .no_op_on_uninitialized_split_context_state
                      .into(),
                  close_split_context_state_on_execution: close_split_context_state_on_execution.into(),
                  source_decrypt_handles: *source_decrypt_handles,
              },
          ))
      }
      *)
      Definition transfer_with_split_proofs (τ : list Ty.t) (α : list Value.t) : M :=
        match τ, α with
        | [],
            [
              token_program_id;
              source_token_account;
              mint;
              destination_token_account;
              new_source_decryptable_available_balance;
              source_account_authority;
              context_accounts;
              source_decrypt_handles
            ] =>
          ltac:(M.monadic
            (let token_program_id := M.alloc (| token_program_id |) in
            let source_token_account := M.alloc (| source_token_account |) in
            let mint := M.alloc (| mint |) in
            let destination_token_account := M.alloc (| destination_token_account |) in
            let new_source_decryptable_available_balance :=
              M.alloc (| new_source_decryptable_available_balance |) in
            let source_account_authority := M.alloc (| source_account_authority |) in
            let context_accounts := M.alloc (| context_accounts |) in
            let source_decrypt_handles := M.alloc (| source_decrypt_handles |) in
            M.catch_return (|
              ltac:(M.monadic
                (M.read (|
                  let _ :=
                    M.match_operator (|
                      M.alloc (|
                        M.call_closure (|
                          M.get_trait_method (|
                            "core::ops::try_trait::Try",
                            Ty.apply
                              (Ty.path "core::result::Result")
                              [ Ty.tuple []; Ty.path "solana_program::program_error::ProgramError"
                              ],
                            [],
                            "branch",
                            []
                          |),
                          [
                            M.call_closure (|
                              M.get_function (| "spl_token_2022::check_program_account", [] |),
                              [ M.read (| token_program_id |) ]
                            |)
                          ]
                        |)
                      |),
                      [
                        fun γ =>
                          ltac:(M.monadic
                            (let γ0_0 :=
                              M.SubPointer.get_struct_tuple_field (|
                                γ,
                                "core::ops::control_flow::ControlFlow::Break",
                                0
                              |) in
                            let residual := M.copy (| γ0_0 |) in
                            M.alloc (|
                              M.never_to_any (|
                                M.read (|
                                  M.return_ (|
                                    M.call_closure (|
                                      M.get_trait_method (|
                                        "core::ops::try_trait::FromResidual",
                                        Ty.apply
                                          (Ty.path "core::result::Result")
                                          [
                                            Ty.path "solana_program::instruction::Instruction";
                                            Ty.path "solana_program::program_error::ProgramError"
                                          ],
                                        [
                                          Ty.apply
                                            (Ty.path "core::result::Result")
                                            [
                                              Ty.path "core::convert::Infallible";
                                              Ty.path "solana_program::program_error::ProgramError"
                                            ]
                                        ],
                                        "from_residual",
                                        []
                                      |),
                                      [ M.read (| residual |) ]
                                    |)
                                  |)
                                |)
                              |)
                            |)));
                        fun γ =>
                          ltac:(M.monadic
                            (let γ0_0 :=
                              M.SubPointer.get_struct_tuple_field (|
                                γ,
                                "core::ops::control_flow::ControlFlow::Continue",
                                0
                              |) in
                            let val := M.copy (| γ0_0 |) in
                            val))
                      ]
                    |) in
                  let accounts :=
                    M.alloc (|
                      M.call_closure (|
                        M.get_associated_function (|
                          Ty.apply
                            (Ty.path "slice")
                            [ Ty.path "solana_program::instruction::AccountMeta" ],
                          "into_vec",
                          [ Ty.path "alloc::alloc::Global" ]
                        |),
                        [
                          (* Unsize *)
                          M.pointer_coercion
                            (M.read (|
                              M.call_closure (|
                                M.get_associated_function (|
                                  Ty.apply
                                    (Ty.path "alloc::boxed::Box")
                                    [
                                      Ty.apply
                                        (Ty.path "array")
                                        [ Ty.path "solana_program::instruction::AccountMeta" ];
                                      Ty.path "alloc::alloc::Global"
                                    ],
                                  "new",
                                  []
                                |),
                                [
                                  M.alloc (|
                                    Value.Array
                                      [
                                        M.call_closure (|
                                          M.get_associated_function (|
                                            Ty.path "solana_program::instruction::AccountMeta",
                                            "new",
                                            []
                                          |),
                                          [
                                            M.read (| M.read (| source_token_account |) |);
                                            Value.Bool false
                                          ]
                                        |);
                                        M.call_closure (|
                                          M.get_associated_function (|
                                            Ty.path "solana_program::instruction::AccountMeta",
                                            "new_readonly",
                                            []
                                          |),
                                          [ M.read (| M.read (| mint |) |); Value.Bool false ]
                                        |);
                                        M.call_closure (|
                                          M.get_associated_function (|
                                            Ty.path "solana_program::instruction::AccountMeta",
                                            "new",
                                            []
                                          |),
                                          [
                                            M.read (| M.read (| destination_token_account |) |);
                                            Value.Bool false
                                          ]
                                        |)
                                      ]
                                  |)
                                ]
                              |)
                            |))
                        ]
                      |)
                    |) in
                  let close_split_context_state_on_execution :=
                    M.copy (|
                      M.match_operator (|
                        M.alloc (| Value.Tuple [] |),
                        [
                          fun γ =>
                            ltac:(M.monadic
                              (let γ :=
                                M.SubPointer.get_struct_record_field (|
                                  context_accounts,
                                  "spl_token_2022::extension::confidential_transfer::instruction::TransferSplitContextStateAccounts",
                                  "close_split_context_state_accounts"
                                |) in
                              let γ0_0 :=
                                M.SubPointer.get_struct_tuple_field (|
                                  γ,
                                  "core::option::Option::Some",
                                  0
                                |) in
                              let close_split_context_state_on_execution_accounts :=
                                M.copy (| γ0_0 |) in
                              let _ :=
                                M.alloc (|
                                  M.call_closure (|
                                    M.get_associated_function (|
                                      Ty.apply
                                        (Ty.path "alloc::vec::Vec")
                                        [
                                          Ty.path "solana_program::instruction::AccountMeta";
                                          Ty.path "alloc::alloc::Global"
                                        ],
                                      "push",
                                      []
                                    |),
                                    [
                                      accounts;
                                      M.call_closure (|
                                        M.get_associated_function (|
                                          Ty.path "solana_program::instruction::AccountMeta",
                                          "new",
                                          []
                                        |),
                                        [
                                          M.read (|
                                            M.read (|
                                              M.SubPointer.get_struct_record_field (|
                                                context_accounts,
                                                "spl_token_2022::extension::confidential_transfer::instruction::TransferSplitContextStateAccounts",
                                                "equality_proof"
                                              |)
                                            |)
                                          |);
                                          Value.Bool false
                                        ]
                                      |)
                                    ]
                                  |)
                                |) in
                              let _ :=
                                M.alloc (|
                                  M.call_closure (|
                                    M.get_associated_function (|
                                      Ty.apply
                                        (Ty.path "alloc::vec::Vec")
                                        [
                                          Ty.path "solana_program::instruction::AccountMeta";
                                          Ty.path "alloc::alloc::Global"
                                        ],
                                      "push",
                                      []
                                    |),
                                    [
                                      accounts;
                                      M.call_closure (|
                                        M.get_associated_function (|
                                          Ty.path "solana_program::instruction::AccountMeta",
                                          "new",
                                          []
                                        |),
                                        [
                                          M.read (|
                                            M.read (|
                                              M.SubPointer.get_struct_record_field (|
                                                context_accounts,
                                                "spl_token_2022::extension::confidential_transfer::instruction::TransferSplitContextStateAccounts",
                                                "ciphertext_validity_proof"
                                              |)
                                            |)
                                          |);
                                          Value.Bool false
                                        ]
                                      |)
                                    ]
                                  |)
                                |) in
                              let _ :=
                                M.alloc (|
                                  M.call_closure (|
                                    M.get_associated_function (|
                                      Ty.apply
                                        (Ty.path "alloc::vec::Vec")
                                        [
                                          Ty.path "solana_program::instruction::AccountMeta";
                                          Ty.path "alloc::alloc::Global"
                                        ],
                                      "push",
                                      []
                                    |),
                                    [
                                      accounts;
                                      M.call_closure (|
                                        M.get_associated_function (|
                                          Ty.path "solana_program::instruction::AccountMeta",
                                          "new",
                                          []
                                        |),
                                        [
                                          M.read (|
                                            M.read (|
                                              M.SubPointer.get_struct_record_field (|
                                                context_accounts,
                                                "spl_token_2022::extension::confidential_transfer::instruction::TransferSplitContextStateAccounts",
                                                "range_proof"
                                              |)
                                            |)
                                          |);
                                          Value.Bool false
                                        ]
                                      |)
                                    ]
                                  |)
                                |) in
                              let _ :=
                                M.alloc (|
                                  M.call_closure (|
                                    M.get_associated_function (|
                                      Ty.apply
                                        (Ty.path "alloc::vec::Vec")
                                        [
                                          Ty.path "solana_program::instruction::AccountMeta";
                                          Ty.path "alloc::alloc::Global"
                                        ],
                                      "push",
                                      []
                                    |),
                                    [
                                      accounts;
                                      M.call_closure (|
                                        M.get_associated_function (|
                                          Ty.path "solana_program::instruction::AccountMeta",
                                          "new",
                                          []
                                        |),
                                        [
                                          M.read (|
                                            M.read (|
                                              M.SubPointer.get_struct_record_field (|
                                                close_split_context_state_on_execution_accounts,
                                                "spl_token_2022::extension::confidential_transfer::instruction::CloseSplitContextStateAccounts",
                                                "lamport_destination"
                                              |)
                                            |)
                                          |);
                                          Value.Bool false
                                        ]
                                      |)
                                    ]
                                  |)
                                |) in
                              let _ :=
                                M.alloc (|
                                  M.call_closure (|
                                    M.get_associated_function (|
                                      Ty.apply
                                        (Ty.path "alloc::vec::Vec")
                                        [
                                          Ty.path "solana_program::instruction::AccountMeta";
                                          Ty.path "alloc::alloc::Global"
                                        ],
                                      "push",
                                      []
                                    |),
                                    [
                                      accounts;
                                      M.call_closure (|
                                        M.get_associated_function (|
                                          Ty.path "solana_program::instruction::AccountMeta",
                                          "new_readonly",
                                          []
                                        |),
                                        [
                                          M.read (|
                                            M.read (|
                                              M.SubPointer.get_struct_record_field (|
                                                context_accounts,
                                                "spl_token_2022::extension::confidential_transfer::instruction::TransferSplitContextStateAccounts",
                                                "authority"
                                              |)
                                            |)
                                          |);
                                          Value.Bool true
                                        ]
                                      |)
                                    ]
                                  |)
                                |) in
                              let _ :=
                                M.alloc (|
                                  M.call_closure (|
                                    M.get_associated_function (|
                                      Ty.apply
                                        (Ty.path "alloc::vec::Vec")
                                        [
                                          Ty.path "solana_program::instruction::AccountMeta";
                                          Ty.path "alloc::alloc::Global"
                                        ],
                                      "push",
                                      []
                                    |),
                                    [
                                      accounts;
                                      M.call_closure (|
                                        M.get_associated_function (|
                                          Ty.path "solana_program::instruction::AccountMeta",
                                          "new_readonly",
                                          []
                                        |),
                                        [
                                          M.read (|
                                            M.read (|
                                              M.SubPointer.get_struct_record_field (|
                                                close_split_context_state_on_execution_accounts,
                                                "spl_token_2022::extension::confidential_transfer::instruction::CloseSplitContextStateAccounts",
                                                "zk_token_proof_program"
                                              |)
                                            |)
                                          |);
                                          Value.Bool false
                                        ]
                                      |)
                                    ]
                                  |)
                                |) in
                              let _ :=
                                M.alloc (|
                                  M.call_closure (|
                                    M.get_associated_function (|
                                      Ty.apply
                                        (Ty.path "alloc::vec::Vec")
                                        [
                                          Ty.path "solana_program::instruction::AccountMeta";
                                          Ty.path "alloc::alloc::Global"
                                        ],
                                      "push",
                                      []
                                    |),
                                    [
                                      accounts;
                                      M.call_closure (|
                                        M.get_associated_function (|
                                          Ty.path "solana_program::instruction::AccountMeta",
                                          "new_readonly",
                                          []
                                        |),
                                        [
                                          M.read (| M.read (| source_account_authority |) |);
                                          Value.Bool true
                                        ]
                                      |)
                                    ]
                                  |)
                                |) in
                              M.alloc (| Value.Bool true |)));
                          fun γ =>
                            ltac:(M.monadic
                              (let _ :=
                                M.alloc (|
                                  M.call_closure (|
                                    M.get_associated_function (|
                                      Ty.apply
                                        (Ty.path "alloc::vec::Vec")
                                        [
                                          Ty.path "solana_program::instruction::AccountMeta";
                                          Ty.path "alloc::alloc::Global"
                                        ],
                                      "push",
                                      []
                                    |),
                                    [
                                      accounts;
                                      M.call_closure (|
                                        M.get_associated_function (|
                                          Ty.path "solana_program::instruction::AccountMeta",
                                          "new_readonly",
                                          []
                                        |),
                                        [
                                          M.read (|
                                            M.read (|
                                              M.SubPointer.get_struct_record_field (|
                                                context_accounts,
                                                "spl_token_2022::extension::confidential_transfer::instruction::TransferSplitContextStateAccounts",
                                                "equality_proof"
                                              |)
                                            |)
                                          |);
                                          Value.Bool false
                                        ]
                                      |)
                                    ]
                                  |)
                                |) in
                              let _ :=
                                M.alloc (|
                                  M.call_closure (|
                                    M.get_associated_function (|
                                      Ty.apply
                                        (Ty.path "alloc::vec::Vec")
                                        [
                                          Ty.path "solana_program::instruction::AccountMeta";
                                          Ty.path "alloc::alloc::Global"
                                        ],
                                      "push",
                                      []
                                    |),
                                    [
                                      accounts;
                                      M.call_closure (|
                                        M.get_associated_function (|
                                          Ty.path "solana_program::instruction::AccountMeta",
                                          "new_readonly",
                                          []
                                        |),
                                        [
                                          M.read (|
                                            M.read (|
                                              M.SubPointer.get_struct_record_field (|
                                                context_accounts,
                                                "spl_token_2022::extension::confidential_transfer::instruction::TransferSplitContextStateAccounts",
                                                "ciphertext_validity_proof"
                                              |)
                                            |)
                                          |);
                                          Value.Bool false
                                        ]
                                      |)
                                    ]
                                  |)
                                |) in
                              let _ :=
                                M.alloc (|
                                  M.call_closure (|
                                    M.get_associated_function (|
                                      Ty.apply
                                        (Ty.path "alloc::vec::Vec")
                                        [
                                          Ty.path "solana_program::instruction::AccountMeta";
                                          Ty.path "alloc::alloc::Global"
                                        ],
                                      "push",
                                      []
                                    |),
                                    [
                                      accounts;
                                      M.call_closure (|
                                        M.get_associated_function (|
                                          Ty.path "solana_program::instruction::AccountMeta",
                                          "new_readonly",
                                          []
                                        |),
                                        [
                                          M.read (|
                                            M.read (|
                                              M.SubPointer.get_struct_record_field (|
                                                context_accounts,
                                                "spl_token_2022::extension::confidential_transfer::instruction::TransferSplitContextStateAccounts",
                                                "range_proof"
                                              |)
                                            |)
                                          |);
                                          Value.Bool false
                                        ]
                                      |)
                                    ]
                                  |)
                                |) in
                              let _ :=
                                M.alloc (|
                                  M.call_closure (|
                                    M.get_associated_function (|
                                      Ty.apply
                                        (Ty.path "alloc::vec::Vec")
                                        [
                                          Ty.path "solana_program::instruction::AccountMeta";
                                          Ty.path "alloc::alloc::Global"
                                        ],
                                      "push",
                                      []
                                    |),
                                    [
                                      accounts;
                                      M.call_closure (|
                                        M.get_associated_function (|
                                          Ty.path "solana_program::instruction::AccountMeta",
                                          "new_readonly",
                                          []
                                        |),
                                        [
                                          M.read (| M.read (| source_account_authority |) |);
                                          Value.Bool true
                                        ]
                                      |)
                                    ]
                                  |)
                                |) in
                              M.alloc (| Value.Bool false |)))
                        ]
                      |)
                    |) in
                  M.alloc (|
                    Value.StructTuple
                      "core::result::Result::Ok"
                      [
                        M.call_closure (|
                          M.get_function (|
                            "spl_token_2022::instruction::encode_instruction",
                            [
                              Ty.path
                                "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction";
                              Ty.path
                                "spl_token_2022::extension::confidential_transfer::instruction::TransferWithSplitProofsInstructionData"
                            ]
                          |),
                          [
                            M.read (| token_program_id |);
                            M.read (| accounts |);
                            Value.StructTuple
                              "spl_token_2022::instruction::TokenInstruction::ConfidentialTransferExtension"
                              [];
                            Value.StructTuple
                              "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction::TransferWithSplitProofs"
                              [];
                            M.alloc (|
                              Value.StructRecord
                                "spl_token_2022::extension::confidential_transfer::instruction::TransferWithSplitProofsInstructionData"
                                [
                                  ("new_source_decryptable_available_balance",
                                    M.read (| new_source_decryptable_available_balance |));
                                  ("no_op_on_uninitialized_split_context_state",
                                    M.call_closure (|
                                      M.get_trait_method (|
                                        "core::convert::Into",
                                        Ty.path "bool",
                                        [ Ty.path "spl_pod::primitives::PodBool" ],
                                        "into",
                                        []
                                      |),
                                      [
                                        M.read (|
                                          M.SubPointer.get_struct_record_field (|
                                            context_accounts,
                                            "spl_token_2022::extension::confidential_transfer::instruction::TransferSplitContextStateAccounts",
                                            "no_op_on_uninitialized_split_context_state"
                                          |)
                                        |)
                                      ]
                                    |));
                                  ("close_split_context_state_on_execution",
                                    M.call_closure (|
                                      M.get_trait_method (|
                                        "core::convert::Into",
                                        Ty.path "bool",
                                        [ Ty.path "spl_pod::primitives::PodBool" ],
                                        "into",
                                        []
                                      |),
                                      [ M.read (| close_split_context_state_on_execution |) ]
                                    |));
                                  ("source_decrypt_handles",
                                    M.read (| M.read (| source_decrypt_handles |) |))
                                ]
                            |)
                          ]
                        |)
                      ]
                  |)
                |)))
            |)))
        | _, _ => M.impossible
        end.
      
      (*
      pub fn transfer_with_fee_and_split_proofs(
          token_program_id: &Pubkey,
          source_token_account: &Pubkey,
          mint: &Pubkey,
          destination_token_account: &Pubkey,
          new_source_decryptable_available_balance: DecryptableBalance,
          source_account_authority: &Pubkey,
          context_accounts: TransferWithFeeSplitContextStateAccounts,
          source_decrypt_handles: &SourceDecryptHandles,
      ) -> Result<Instruction, ProgramError> {
          check_program_account(token_program_id)?;
          let mut accounts = vec![
              AccountMeta::new( *source_token_account, false),
              AccountMeta::new_readonly( *mint, false),
              AccountMeta::new( *destination_token_account, false),
          ];
      
          let close_split_context_state_on_execution =
              if let Some(close_split_context_state_on_execution_accounts) =
                  context_accounts.close_split_context_state_accounts
              {
                  // If `close_split_context_state_accounts` is set, then all context state
                  // accounts must be `writable`.
                  accounts.push(AccountMeta::new( *context_accounts.equality_proof, false));
                  accounts.push(AccountMeta::new(
                      *context_accounts.transfer_amount_ciphertext_validity_proof,
                      false,
                  ));
                  accounts.push(AccountMeta::new( *context_accounts.fee_sigma_proof, false));
                  accounts.push(AccountMeta::new(
                      *context_accounts.fee_ciphertext_validity_proof,
                      false,
                  ));
                  accounts.push(AccountMeta::new( *context_accounts.range_proof, false));
                  accounts.push(AccountMeta::new(
                      *close_split_context_state_on_execution_accounts.lamport_destination,
                      false,
                  ));
                  accounts.push(AccountMeta::new_readonly( *context_accounts.authority, true));
                  accounts.push(AccountMeta::new_readonly(
                      *close_split_context_state_on_execution_accounts.zk_token_proof_program,
                      false,
                  ));
                  accounts.push(AccountMeta::new_readonly( *source_account_authority, true));
                  true
              } else {
                  // If `close_split_context_state_accounts` is not set, then context state
                  // accounts can be read-only.
                  accounts.push(AccountMeta::new_readonly(
                      *context_accounts.equality_proof,
                      false,
                  ));
                  accounts.push(AccountMeta::new_readonly(
                      *context_accounts.transfer_amount_ciphertext_validity_proof,
                      false,
                  ));
                  accounts.push(AccountMeta::new_readonly(
                      *context_accounts.fee_sigma_proof,
                      false,
                  ));
                  accounts.push(AccountMeta::new_readonly(
                      *context_accounts.fee_ciphertext_validity_proof,
                      false,
                  ));
                  accounts.push(AccountMeta::new_readonly(
                      *context_accounts.range_proof,
                      false,
                  ));
                  accounts.push(AccountMeta::new_readonly( *source_account_authority, true));
                  false
              };
      
          Ok(encode_instruction(
              token_program_id,
              accounts,
              TokenInstruction::ConfidentialTransferExtension,
              ConfidentialTransferInstruction::TransferWithSplitProofs,
              &TransferWithSplitProofsInstructionData {
                  new_source_decryptable_available_balance,
                  no_op_on_uninitialized_split_context_state: context_accounts
                      .no_op_on_uninitialized_split_context_state
                      .into(),
                  close_split_context_state_on_execution: close_split_context_state_on_execution.into(),
                  source_decrypt_handles: *source_decrypt_handles,
              },
          ))
      }
      *)
      Definition transfer_with_fee_and_split_proofs (τ : list Ty.t) (α : list Value.t) : M :=
        match τ, α with
        | [],
            [
              token_program_id;
              source_token_account;
              mint;
              destination_token_account;
              new_source_decryptable_available_balance;
              source_account_authority;
              context_accounts;
              source_decrypt_handles
            ] =>
          ltac:(M.monadic
            (let token_program_id := M.alloc (| token_program_id |) in
            let source_token_account := M.alloc (| source_token_account |) in
            let mint := M.alloc (| mint |) in
            let destination_token_account := M.alloc (| destination_token_account |) in
            let new_source_decryptable_available_balance :=
              M.alloc (| new_source_decryptable_available_balance |) in
            let source_account_authority := M.alloc (| source_account_authority |) in
            let context_accounts := M.alloc (| context_accounts |) in
            let source_decrypt_handles := M.alloc (| source_decrypt_handles |) in
            M.catch_return (|
              ltac:(M.monadic
                (M.read (|
                  let _ :=
                    M.match_operator (|
                      M.alloc (|
                        M.call_closure (|
                          M.get_trait_method (|
                            "core::ops::try_trait::Try",
                            Ty.apply
                              (Ty.path "core::result::Result")
                              [ Ty.tuple []; Ty.path "solana_program::program_error::ProgramError"
                              ],
                            [],
                            "branch",
                            []
                          |),
                          [
                            M.call_closure (|
                              M.get_function (| "spl_token_2022::check_program_account", [] |),
                              [ M.read (| token_program_id |) ]
                            |)
                          ]
                        |)
                      |),
                      [
                        fun γ =>
                          ltac:(M.monadic
                            (let γ0_0 :=
                              M.SubPointer.get_struct_tuple_field (|
                                γ,
                                "core::ops::control_flow::ControlFlow::Break",
                                0
                              |) in
                            let residual := M.copy (| γ0_0 |) in
                            M.alloc (|
                              M.never_to_any (|
                                M.read (|
                                  M.return_ (|
                                    M.call_closure (|
                                      M.get_trait_method (|
                                        "core::ops::try_trait::FromResidual",
                                        Ty.apply
                                          (Ty.path "core::result::Result")
                                          [
                                            Ty.path "solana_program::instruction::Instruction";
                                            Ty.path "solana_program::program_error::ProgramError"
                                          ],
                                        [
                                          Ty.apply
                                            (Ty.path "core::result::Result")
                                            [
                                              Ty.path "core::convert::Infallible";
                                              Ty.path "solana_program::program_error::ProgramError"
                                            ]
                                        ],
                                        "from_residual",
                                        []
                                      |),
                                      [ M.read (| residual |) ]
                                    |)
                                  |)
                                |)
                              |)
                            |)));
                        fun γ =>
                          ltac:(M.monadic
                            (let γ0_0 :=
                              M.SubPointer.get_struct_tuple_field (|
                                γ,
                                "core::ops::control_flow::ControlFlow::Continue",
                                0
                              |) in
                            let val := M.copy (| γ0_0 |) in
                            val))
                      ]
                    |) in
                  let accounts :=
                    M.alloc (|
                      M.call_closure (|
                        M.get_associated_function (|
                          Ty.apply
                            (Ty.path "slice")
                            [ Ty.path "solana_program::instruction::AccountMeta" ],
                          "into_vec",
                          [ Ty.path "alloc::alloc::Global" ]
                        |),
                        [
                          (* Unsize *)
                          M.pointer_coercion
                            (M.read (|
                              M.call_closure (|
                                M.get_associated_function (|
                                  Ty.apply
                                    (Ty.path "alloc::boxed::Box")
                                    [
                                      Ty.apply
                                        (Ty.path "array")
                                        [ Ty.path "solana_program::instruction::AccountMeta" ];
                                      Ty.path "alloc::alloc::Global"
                                    ],
                                  "new",
                                  []
                                |),
                                [
                                  M.alloc (|
                                    Value.Array
                                      [
                                        M.call_closure (|
                                          M.get_associated_function (|
                                            Ty.path "solana_program::instruction::AccountMeta",
                                            "new",
                                            []
                                          |),
                                          [
                                            M.read (| M.read (| source_token_account |) |);
                                            Value.Bool false
                                          ]
                                        |);
                                        M.call_closure (|
                                          M.get_associated_function (|
                                            Ty.path "solana_program::instruction::AccountMeta",
                                            "new_readonly",
                                            []
                                          |),
                                          [ M.read (| M.read (| mint |) |); Value.Bool false ]
                                        |);
                                        M.call_closure (|
                                          M.get_associated_function (|
                                            Ty.path "solana_program::instruction::AccountMeta",
                                            "new",
                                            []
                                          |),
                                          [
                                            M.read (| M.read (| destination_token_account |) |);
                                            Value.Bool false
                                          ]
                                        |)
                                      ]
                                  |)
                                ]
                              |)
                            |))
                        ]
                      |)
                    |) in
                  let close_split_context_state_on_execution :=
                    M.copy (|
                      M.match_operator (|
                        M.alloc (| Value.Tuple [] |),
                        [
                          fun γ =>
                            ltac:(M.monadic
                              (let γ :=
                                M.SubPointer.get_struct_record_field (|
                                  context_accounts,
                                  "spl_token_2022::extension::confidential_transfer::instruction::TransferWithFeeSplitContextStateAccounts",
                                  "close_split_context_state_accounts"
                                |) in
                              let γ0_0 :=
                                M.SubPointer.get_struct_tuple_field (|
                                  γ,
                                  "core::option::Option::Some",
                                  0
                                |) in
                              let close_split_context_state_on_execution_accounts :=
                                M.copy (| γ0_0 |) in
                              let _ :=
                                M.alloc (|
                                  M.call_closure (|
                                    M.get_associated_function (|
                                      Ty.apply
                                        (Ty.path "alloc::vec::Vec")
                                        [
                                          Ty.path "solana_program::instruction::AccountMeta";
                                          Ty.path "alloc::alloc::Global"
                                        ],
                                      "push",
                                      []
                                    |),
                                    [
                                      accounts;
                                      M.call_closure (|
                                        M.get_associated_function (|
                                          Ty.path "solana_program::instruction::AccountMeta",
                                          "new",
                                          []
                                        |),
                                        [
                                          M.read (|
                                            M.read (|
                                              M.SubPointer.get_struct_record_field (|
                                                context_accounts,
                                                "spl_token_2022::extension::confidential_transfer::instruction::TransferWithFeeSplitContextStateAccounts",
                                                "equality_proof"
                                              |)
                                            |)
                                          |);
                                          Value.Bool false
                                        ]
                                      |)
                                    ]
                                  |)
                                |) in
                              let _ :=
                                M.alloc (|
                                  M.call_closure (|
                                    M.get_associated_function (|
                                      Ty.apply
                                        (Ty.path "alloc::vec::Vec")
                                        [
                                          Ty.path "solana_program::instruction::AccountMeta";
                                          Ty.path "alloc::alloc::Global"
                                        ],
                                      "push",
                                      []
                                    |),
                                    [
                                      accounts;
                                      M.call_closure (|
                                        M.get_associated_function (|
                                          Ty.path "solana_program::instruction::AccountMeta",
                                          "new",
                                          []
                                        |),
                                        [
                                          M.read (|
                                            M.read (|
                                              M.SubPointer.get_struct_record_field (|
                                                context_accounts,
                                                "spl_token_2022::extension::confidential_transfer::instruction::TransferWithFeeSplitContextStateAccounts",
                                                "transfer_amount_ciphertext_validity_proof"
                                              |)
                                            |)
                                          |);
                                          Value.Bool false
                                        ]
                                      |)
                                    ]
                                  |)
                                |) in
                              let _ :=
                                M.alloc (|
                                  M.call_closure (|
                                    M.get_associated_function (|
                                      Ty.apply
                                        (Ty.path "alloc::vec::Vec")
                                        [
                                          Ty.path "solana_program::instruction::AccountMeta";
                                          Ty.path "alloc::alloc::Global"
                                        ],
                                      "push",
                                      []
                                    |),
                                    [
                                      accounts;
                                      M.call_closure (|
                                        M.get_associated_function (|
                                          Ty.path "solana_program::instruction::AccountMeta",
                                          "new",
                                          []
                                        |),
                                        [
                                          M.read (|
                                            M.read (|
                                              M.SubPointer.get_struct_record_field (|
                                                context_accounts,
                                                "spl_token_2022::extension::confidential_transfer::instruction::TransferWithFeeSplitContextStateAccounts",
                                                "fee_sigma_proof"
                                              |)
                                            |)
                                          |);
                                          Value.Bool false
                                        ]
                                      |)
                                    ]
                                  |)
                                |) in
                              let _ :=
                                M.alloc (|
                                  M.call_closure (|
                                    M.get_associated_function (|
                                      Ty.apply
                                        (Ty.path "alloc::vec::Vec")
                                        [
                                          Ty.path "solana_program::instruction::AccountMeta";
                                          Ty.path "alloc::alloc::Global"
                                        ],
                                      "push",
                                      []
                                    |),
                                    [
                                      accounts;
                                      M.call_closure (|
                                        M.get_associated_function (|
                                          Ty.path "solana_program::instruction::AccountMeta",
                                          "new",
                                          []
                                        |),
                                        [
                                          M.read (|
                                            M.read (|
                                              M.SubPointer.get_struct_record_field (|
                                                context_accounts,
                                                "spl_token_2022::extension::confidential_transfer::instruction::TransferWithFeeSplitContextStateAccounts",
                                                "fee_ciphertext_validity_proof"
                                              |)
                                            |)
                                          |);
                                          Value.Bool false
                                        ]
                                      |)
                                    ]
                                  |)
                                |) in
                              let _ :=
                                M.alloc (|
                                  M.call_closure (|
                                    M.get_associated_function (|
                                      Ty.apply
                                        (Ty.path "alloc::vec::Vec")
                                        [
                                          Ty.path "solana_program::instruction::AccountMeta";
                                          Ty.path "alloc::alloc::Global"
                                        ],
                                      "push",
                                      []
                                    |),
                                    [
                                      accounts;
                                      M.call_closure (|
                                        M.get_associated_function (|
                                          Ty.path "solana_program::instruction::AccountMeta",
                                          "new",
                                          []
                                        |),
                                        [
                                          M.read (|
                                            M.read (|
                                              M.SubPointer.get_struct_record_field (|
                                                context_accounts,
                                                "spl_token_2022::extension::confidential_transfer::instruction::TransferWithFeeSplitContextStateAccounts",
                                                "range_proof"
                                              |)
                                            |)
                                          |);
                                          Value.Bool false
                                        ]
                                      |)
                                    ]
                                  |)
                                |) in
                              let _ :=
                                M.alloc (|
                                  M.call_closure (|
                                    M.get_associated_function (|
                                      Ty.apply
                                        (Ty.path "alloc::vec::Vec")
                                        [
                                          Ty.path "solana_program::instruction::AccountMeta";
                                          Ty.path "alloc::alloc::Global"
                                        ],
                                      "push",
                                      []
                                    |),
                                    [
                                      accounts;
                                      M.call_closure (|
                                        M.get_associated_function (|
                                          Ty.path "solana_program::instruction::AccountMeta",
                                          "new",
                                          []
                                        |),
                                        [
                                          M.read (|
                                            M.read (|
                                              M.SubPointer.get_struct_record_field (|
                                                close_split_context_state_on_execution_accounts,
                                                "spl_token_2022::extension::confidential_transfer::instruction::CloseSplitContextStateAccounts",
                                                "lamport_destination"
                                              |)
                                            |)
                                          |);
                                          Value.Bool false
                                        ]
                                      |)
                                    ]
                                  |)
                                |) in
                              let _ :=
                                M.alloc (|
                                  M.call_closure (|
                                    M.get_associated_function (|
                                      Ty.apply
                                        (Ty.path "alloc::vec::Vec")
                                        [
                                          Ty.path "solana_program::instruction::AccountMeta";
                                          Ty.path "alloc::alloc::Global"
                                        ],
                                      "push",
                                      []
                                    |),
                                    [
                                      accounts;
                                      M.call_closure (|
                                        M.get_associated_function (|
                                          Ty.path "solana_program::instruction::AccountMeta",
                                          "new_readonly",
                                          []
                                        |),
                                        [
                                          M.read (|
                                            M.read (|
                                              M.SubPointer.get_struct_record_field (|
                                                context_accounts,
                                                "spl_token_2022::extension::confidential_transfer::instruction::TransferWithFeeSplitContextStateAccounts",
                                                "authority"
                                              |)
                                            |)
                                          |);
                                          Value.Bool true
                                        ]
                                      |)
                                    ]
                                  |)
                                |) in
                              let _ :=
                                M.alloc (|
                                  M.call_closure (|
                                    M.get_associated_function (|
                                      Ty.apply
                                        (Ty.path "alloc::vec::Vec")
                                        [
                                          Ty.path "solana_program::instruction::AccountMeta";
                                          Ty.path "alloc::alloc::Global"
                                        ],
                                      "push",
                                      []
                                    |),
                                    [
                                      accounts;
                                      M.call_closure (|
                                        M.get_associated_function (|
                                          Ty.path "solana_program::instruction::AccountMeta",
                                          "new_readonly",
                                          []
                                        |),
                                        [
                                          M.read (|
                                            M.read (|
                                              M.SubPointer.get_struct_record_field (|
                                                close_split_context_state_on_execution_accounts,
                                                "spl_token_2022::extension::confidential_transfer::instruction::CloseSplitContextStateAccounts",
                                                "zk_token_proof_program"
                                              |)
                                            |)
                                          |);
                                          Value.Bool false
                                        ]
                                      |)
                                    ]
                                  |)
                                |) in
                              let _ :=
                                M.alloc (|
                                  M.call_closure (|
                                    M.get_associated_function (|
                                      Ty.apply
                                        (Ty.path "alloc::vec::Vec")
                                        [
                                          Ty.path "solana_program::instruction::AccountMeta";
                                          Ty.path "alloc::alloc::Global"
                                        ],
                                      "push",
                                      []
                                    |),
                                    [
                                      accounts;
                                      M.call_closure (|
                                        M.get_associated_function (|
                                          Ty.path "solana_program::instruction::AccountMeta",
                                          "new_readonly",
                                          []
                                        |),
                                        [
                                          M.read (| M.read (| source_account_authority |) |);
                                          Value.Bool true
                                        ]
                                      |)
                                    ]
                                  |)
                                |) in
                              M.alloc (| Value.Bool true |)));
                          fun γ =>
                            ltac:(M.monadic
                              (let _ :=
                                M.alloc (|
                                  M.call_closure (|
                                    M.get_associated_function (|
                                      Ty.apply
                                        (Ty.path "alloc::vec::Vec")
                                        [
                                          Ty.path "solana_program::instruction::AccountMeta";
                                          Ty.path "alloc::alloc::Global"
                                        ],
                                      "push",
                                      []
                                    |),
                                    [
                                      accounts;
                                      M.call_closure (|
                                        M.get_associated_function (|
                                          Ty.path "solana_program::instruction::AccountMeta",
                                          "new_readonly",
                                          []
                                        |),
                                        [
                                          M.read (|
                                            M.read (|
                                              M.SubPointer.get_struct_record_field (|
                                                context_accounts,
                                                "spl_token_2022::extension::confidential_transfer::instruction::TransferWithFeeSplitContextStateAccounts",
                                                "equality_proof"
                                              |)
                                            |)
                                          |);
                                          Value.Bool false
                                        ]
                                      |)
                                    ]
                                  |)
                                |) in
                              let _ :=
                                M.alloc (|
                                  M.call_closure (|
                                    M.get_associated_function (|
                                      Ty.apply
                                        (Ty.path "alloc::vec::Vec")
                                        [
                                          Ty.path "solana_program::instruction::AccountMeta";
                                          Ty.path "alloc::alloc::Global"
                                        ],
                                      "push",
                                      []
                                    |),
                                    [
                                      accounts;
                                      M.call_closure (|
                                        M.get_associated_function (|
                                          Ty.path "solana_program::instruction::AccountMeta",
                                          "new_readonly",
                                          []
                                        |),
                                        [
                                          M.read (|
                                            M.read (|
                                              M.SubPointer.get_struct_record_field (|
                                                context_accounts,
                                                "spl_token_2022::extension::confidential_transfer::instruction::TransferWithFeeSplitContextStateAccounts",
                                                "transfer_amount_ciphertext_validity_proof"
                                              |)
                                            |)
                                          |);
                                          Value.Bool false
                                        ]
                                      |)
                                    ]
                                  |)
                                |) in
                              let _ :=
                                M.alloc (|
                                  M.call_closure (|
                                    M.get_associated_function (|
                                      Ty.apply
                                        (Ty.path "alloc::vec::Vec")
                                        [
                                          Ty.path "solana_program::instruction::AccountMeta";
                                          Ty.path "alloc::alloc::Global"
                                        ],
                                      "push",
                                      []
                                    |),
                                    [
                                      accounts;
                                      M.call_closure (|
                                        M.get_associated_function (|
                                          Ty.path "solana_program::instruction::AccountMeta",
                                          "new_readonly",
                                          []
                                        |),
                                        [
                                          M.read (|
                                            M.read (|
                                              M.SubPointer.get_struct_record_field (|
                                                context_accounts,
                                                "spl_token_2022::extension::confidential_transfer::instruction::TransferWithFeeSplitContextStateAccounts",
                                                "fee_sigma_proof"
                                              |)
                                            |)
                                          |);
                                          Value.Bool false
                                        ]
                                      |)
                                    ]
                                  |)
                                |) in
                              let _ :=
                                M.alloc (|
                                  M.call_closure (|
                                    M.get_associated_function (|
                                      Ty.apply
                                        (Ty.path "alloc::vec::Vec")
                                        [
                                          Ty.path "solana_program::instruction::AccountMeta";
                                          Ty.path "alloc::alloc::Global"
                                        ],
                                      "push",
                                      []
                                    |),
                                    [
                                      accounts;
                                      M.call_closure (|
                                        M.get_associated_function (|
                                          Ty.path "solana_program::instruction::AccountMeta",
                                          "new_readonly",
                                          []
                                        |),
                                        [
                                          M.read (|
                                            M.read (|
                                              M.SubPointer.get_struct_record_field (|
                                                context_accounts,
                                                "spl_token_2022::extension::confidential_transfer::instruction::TransferWithFeeSplitContextStateAccounts",
                                                "fee_ciphertext_validity_proof"
                                              |)
                                            |)
                                          |);
                                          Value.Bool false
                                        ]
                                      |)
                                    ]
                                  |)
                                |) in
                              let _ :=
                                M.alloc (|
                                  M.call_closure (|
                                    M.get_associated_function (|
                                      Ty.apply
                                        (Ty.path "alloc::vec::Vec")
                                        [
                                          Ty.path "solana_program::instruction::AccountMeta";
                                          Ty.path "alloc::alloc::Global"
                                        ],
                                      "push",
                                      []
                                    |),
                                    [
                                      accounts;
                                      M.call_closure (|
                                        M.get_associated_function (|
                                          Ty.path "solana_program::instruction::AccountMeta",
                                          "new_readonly",
                                          []
                                        |),
                                        [
                                          M.read (|
                                            M.read (|
                                              M.SubPointer.get_struct_record_field (|
                                                context_accounts,
                                                "spl_token_2022::extension::confidential_transfer::instruction::TransferWithFeeSplitContextStateAccounts",
                                                "range_proof"
                                              |)
                                            |)
                                          |);
                                          Value.Bool false
                                        ]
                                      |)
                                    ]
                                  |)
                                |) in
                              let _ :=
                                M.alloc (|
                                  M.call_closure (|
                                    M.get_associated_function (|
                                      Ty.apply
                                        (Ty.path "alloc::vec::Vec")
                                        [
                                          Ty.path "solana_program::instruction::AccountMeta";
                                          Ty.path "alloc::alloc::Global"
                                        ],
                                      "push",
                                      []
                                    |),
                                    [
                                      accounts;
                                      M.call_closure (|
                                        M.get_associated_function (|
                                          Ty.path "solana_program::instruction::AccountMeta",
                                          "new_readonly",
                                          []
                                        |),
                                        [
                                          M.read (| M.read (| source_account_authority |) |);
                                          Value.Bool true
                                        ]
                                      |)
                                    ]
                                  |)
                                |) in
                              M.alloc (| Value.Bool false |)))
                        ]
                      |)
                    |) in
                  M.alloc (|
                    Value.StructTuple
                      "core::result::Result::Ok"
                      [
                        M.call_closure (|
                          M.get_function (|
                            "spl_token_2022::instruction::encode_instruction",
                            [
                              Ty.path
                                "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction";
                              Ty.path
                                "spl_token_2022::extension::confidential_transfer::instruction::TransferWithSplitProofsInstructionData"
                            ]
                          |),
                          [
                            M.read (| token_program_id |);
                            M.read (| accounts |);
                            Value.StructTuple
                              "spl_token_2022::instruction::TokenInstruction::ConfidentialTransferExtension"
                              [];
                            Value.StructTuple
                              "spl_token_2022::extension::confidential_transfer::instruction::ConfidentialTransferInstruction::TransferWithSplitProofs"
                              [];
                            M.alloc (|
                              Value.StructRecord
                                "spl_token_2022::extension::confidential_transfer::instruction::TransferWithSplitProofsInstructionData"
                                [
                                  ("new_source_decryptable_available_balance",
                                    M.read (| new_source_decryptable_available_balance |));
                                  ("no_op_on_uninitialized_split_context_state",
                                    M.call_closure (|
                                      M.get_trait_method (|
                                        "core::convert::Into",
                                        Ty.path "bool",
                                        [ Ty.path "spl_pod::primitives::PodBool" ],
                                        "into",
                                        []
                                      |),
                                      [
                                        M.read (|
                                          M.SubPointer.get_struct_record_field (|
                                            context_accounts,
                                            "spl_token_2022::extension::confidential_transfer::instruction::TransferWithFeeSplitContextStateAccounts",
                                            "no_op_on_uninitialized_split_context_state"
                                          |)
                                        |)
                                      ]
                                    |));
                                  ("close_split_context_state_on_execution",
                                    M.call_closure (|
                                      M.get_trait_method (|
                                        "core::convert::Into",
                                        Ty.path "bool",
                                        [ Ty.path "spl_pod::primitives::PodBool" ],
                                        "into",
                                        []
                                      |),
                                      [ M.read (| close_split_context_state_on_execution |) ]
                                    |));
                                  ("source_decrypt_handles",
                                    M.read (| M.read (| source_decrypt_handles |) |))
                                ]
                            |)
                          ]
                        |)
                      ]
                  |)
                |)))
            |)))
        | _, _ => M.impossible
        end.
    End instruction.
  End confidential_transfer.
End extension.
