• Top
    • Documentation
    • Books
    • Boolean-reasoning
    • Projects
    • Debugging
    • Community
    • Std
    • Proof-automation
    • Macro-libraries
    • ACL2
    • Interfacing-tools
    • Hardware-verification
    • Software-verification
      • Kestrel-books
        • Crypto-hdwallet
          • Command-error
          • Sign
          • Init-from-mnemonic
          • Command-error-message
          • Stat
          • Next-key
          • Init-from-entropy
          • Process-command
          • Transaction-message
          • Maybe-command-error
          • Maybe-stat
            • Maybe-stat-fix
            • Maybe-stat-case
            • Maybe-stat-equiv
            • Maybe-stat-some
              • Maybe-stat-some->val
                • Make-maybe-stat-some
                • Change-maybe-stat-some
              • Maybe-stat-none
              • Maybe-statp
            • Check-stat-file-present
            • Valid-key-path-p
            • String-to-byte-list
            • Load-stat
            • Mnemonic-message
            • Process-sign
            • Process-init-from-entropy
            • All-valid-key-paths-p
            • String-to-word
            • String-to-nat
            • Process-next-key
            • Wallet
            • Process-init-from-mnemonic
            • Check-stat-file-absent
            • Stat-wfp
            • Save-stat
            • Stat-addresses-bounded-p
            • Stat-all-valid-key-paths-p
            • Stat-priv-keys-p
            • Stat-root-depth-zero-p
            • Stat-path-prefix-in-tree-p
            • Crypto-hdwallet-executable
            • *stat-filepath*
            • *key-path-prefix*
            • *coin-type-index*
            • *purpose-index*
            • *external-chain-index*
            • *command-name-init-from-mnemonic*
            • *command-name-init-from-entropy*
            • *account-index*
            • *command-name-sign*
            • *command-name-next-key*
          • Apt
          • Error-checking
          • Fty-extensions
          • Isar
          • Kestrel-utilities
          • Set
          • C
          • Soft
          • Bv
          • Imp-language
          • Ethereum
          • Event-macros
          • Java
          • Riscv
          • Bitcoin
          • Zcash
          • Yul
          • ACL2-programming-language
          • Prime-fields
          • Json
          • Syntheto
          • File-io-light
          • Cryptography
          • Number-theory
          • Axe
          • Lists-light
          • Builtins
          • Solidity
          • Helpers
          • Htclient
          • Typed-lists-light
          • Arithmetic-light
        • X86isa
        • Axe
        • Execloader
      • Math
      • Testing-utilities
    • Maybe-stat-some

    Maybe-stat-some->val

    Get the fty::val field from a maybe-stat-some.

    Signature
    (maybe-stat-some->val x) → fty::val
    Arguments
    x — Guard (maybe-statp x).
    Returns
    fty::val — Type (statp fty::val).

    This is an ordinary field accessor created by fty::defprod.

    Definitions and Theorems

    Function: maybe-stat-some->val$inline

    (defun maybe-stat-some->val$inline (x)
      (declare (xargs :guard (maybe-statp x)))
      (declare (xargs :guard x))
      (let ((__function__ 'maybe-stat-some->val))
        (declare (ignorable __function__))
        (mbe :logic (b* ((x (and x x))) (stat-fix x))
             :exec x)))

    Theorem: statp-of-maybe-stat-some->val

    (defthm statp-of-maybe-stat-some->val
      (b* ((fty::val (maybe-stat-some->val$inline x)))
        (statp fty::val))
      :rule-classes :rewrite)

    Theorem: maybe-stat-some->val$inline-of-maybe-stat-fix-x

    (defthm maybe-stat-some->val$inline-of-maybe-stat-fix-x
      (equal (maybe-stat-some->val$inline (maybe-stat-fix x))
             (maybe-stat-some->val$inline x)))

    Theorem: maybe-stat-some->val$inline-maybe-stat-equiv-congruence-on-x

    (defthm maybe-stat-some->val$inline-maybe-stat-equiv-congruence-on-x
      (implies (maybe-stat-equiv x x-equiv)
               (equal (maybe-stat-some->val$inline x)
                      (maybe-stat-some->val$inline x-equiv)))
      :rule-classes :congruence)

    Theorem: maybe-stat-some->val-when-wrong-kind

    (defthm maybe-stat-some->val-when-wrong-kind
      (implies (not x)
               (equal (maybe-stat-some->val x)
                      (stat-fix nil))))