• Top
    • Documentation
    • Books
    • Boolean-reasoning
    • Projects
      • Apt
      • Zfc
      • Acre
      • Milawa
      • Smtlink
      • Abnf
      • Vwsim
      • Isar
      • Wp-gen
      • Dimacs-reader
      • Pfcs
      • Legacy-defrstobj
      • Proof-checker-array
      • Soft
      • C
      • Farray
      • Rp-rewriter
      • Instant-runoff-voting
      • Imp-language
      • Sidekick
      • Leftist-trees
      • Java
      • Taspi
      • Bitcoin
      • Riscv
      • Des
      • Ethereum
        • Mmp-trees
        • Semaphore
        • Database
        • Cryptography
        • Rlp
        • Transactions
          • Make-signed-transaction
          • Transaction
            • Transaction-fix
            • Make-transaction
            • Transaction-equiv
            • Transactionp
              • Change-transaction
              • Transaction->init/data
              • Transaction->gas-price
              • Transaction->gas-limit
              • Transaction->value
              • Transaction->to
              • Transaction->sign-v
              • Transaction->sign-s
              • Transaction->sign-r
              • Transaction->nonce
            • Maybe-byte-list20
            • Rlp-decode-transaction
            • Rlp-encode-transaction
            • Rlp-transaction-encoding-p
          • Hex-prefix
          • Basics
          • Addresses
        • X86isa
        • Sha-2
        • Yul
        • Zcash
        • Proof-checker-itp13
        • Regex
        • ACL2-programming-language
        • Json
        • Jfkr
        • Equational
        • Cryptography
        • Poseidon
        • Where-do-i-place-my-book
        • Axe
        • Bigmems
        • Builtins
        • Execloader
        • Aleo
        • Solidity
        • Paco
        • Concurrent-programs
        • Bls12-377-curves
      • Debugging
      • Std
      • Proof-automation
      • Macro-libraries
      • ACL2
      • Interfacing-tools
      • Hardware-verification
      • Software-verification
      • Math
      • Testing-utilities
    • Transaction

    Transactionp

    Recognizer for transaction structures.

    Signature
    (transactionp x) → *

    Definitions and Theorems

    Function: transactionp

    (defun transactionp (x)
      (declare (xargs :guard t))
      (let ((__function__ 'transactionp))
        (declare (ignorable __function__))
        (and (consp x)
             (eq (car x) :transaction)
             (true-listp (cdr x))
             (eql (len (cdr x)) 9)
             (b* ((nonce (std::da-nth 0 (cdr x)))
                  (gas-price (std::da-nth 1 (cdr x)))
                  (gas-limit (std::da-nth 2 (cdr x)))
                  (to (std::da-nth 3 (cdr x)))
                  (value (std::da-nth 4 (cdr x)))
                  (init/data (std::da-nth 5 (cdr x)))
                  (sign-v (std::da-nth 6 (cdr x)))
                  (sign-r (std::da-nth 7 (cdr x)))
                  (sign-s (std::da-nth 8 (cdr x))))
               (and (wordp nonce)
                    (wordp gas-price)
                    (wordp gas-limit)
                    (maybe-byte-list20p to)
                    (wordp value)
                    (byte-listp init/data)
                    (natp sign-v)
                    (wordp sign-r)
                    (wordp sign-s))))))

    Theorem: consp-when-transactionp

    (defthm consp-when-transactionp
      (implies (transactionp x) (consp x))
      :rule-classes :compound-recognizer)