• 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
      • 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
        • Aleobft
          • Aleobft-static
          • Aleobft-stake2
          • Aleobft-dynamic
          • Aleobft-stake
          • Aleobft-proposals
            • Correctness
            • Definition
              • Initialization
              • Transitions
              • States
                • Committees
                • System-states
                • Certificates
                • Transactions
                • Proposals
                  • Proposal
                    • Proposal-fix
                    • Proposalp
                      • Proposal-equiv
                      • Make-proposal
                      • Proposal->transactions
                      • Change-proposal
                      • Proposal->previous
                      • Proposal->round
                      • Proposal->author
                    • Props-with-author+round
                    • Props-with-round
                    • Prop-set-unequivp
                    • Proposal-option
                    • Prop-set-none-author-p
                    • Prop-set-all-author-p
                    • Proposal-set
                  • Messages
                  • Validator-states
                  • Blocks
                  • Addresses
                • Events
                • Reachability
            • Library-extensions
          • Leo
        • Solidity
        • Paco
        • Concurrent-programs
        • Bls12-377-curves
      • Debugging
      • Std
      • Proof-automation
      • Macro-libraries
      • ACL2
      • Interfacing-tools
      • Hardware-verification
      • Software-verification
      • Math
      • Testing-utilities
    • Proposal

    Proposalp

    Recognizer for proposal structures.

    Signature
    (proposalp x) → *

    Definitions and Theorems

    Function: proposalp

    (defun proposalp (x)
     (declare (xargs :guard t))
     (let ((__function__ 'proposalp))
      (declare (ignorable __function__))
      (and
       (mbe
          :logic (and (alistp x)
                      (equal (strip-cars x)
                             '(author round transactions previous)))
          :exec
          (fty::alist-with-carsp x
                                 '(author round transactions previous)))
       (b* ((author (cdr (std::da-nth 0 x)))
            (round (cdr (std::da-nth 1 x)))
            (transactions (cdr (std::da-nth 2 x)))
            (previous (cdr (std::da-nth 3 x))))
         (and (addressp author)
              (posp round)
              (transaction-listp transactions)
              (address-setp previous))))))

    Theorem: consp-when-proposalp

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