• 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

    Make-proposal

    Basic constructor macro for proposal structures.

    Syntax
    (make-proposal [:author <author>] 
                   [:round <round>] 
                   [:transactions <transactions>] 
                   [:previous <previous>]) 
    

    This is the usual way to construct proposal structures. It simply conses together a structure with the specified fields.

    This macro generates a new proposal structure from scratch. See also change-proposal, which can "change" an existing structure, instead.

    Definition

    This is an ordinary make- macro introduced by fty::defprod.

    Macro: make-proposal

    (defmacro make-proposal (&rest args)
      (std::make-aggregate 'proposal
                           args
                           '((:author)
                             (:round)
                             (:transactions)
                             (:previous))
                           'make-proposal
                           nil))

    Function: proposal

    (defun proposal (author round transactions previous)
     (declare (xargs :guard (and (addressp author)
                                 (posp round)
                                 (transaction-listp transactions)
                                 (address-setp previous))))
     (declare (xargs :guard t))
     (let ((__function__ 'proposal))
      (declare (ignorable __function__))
      (b* ((author (mbe :logic (address-fix author)
                        :exec author))
           (round (mbe :logic (pos-fix round)
                       :exec round))
           (transactions (mbe :logic (transaction-list-fix transactions)
                              :exec transactions))
           (previous (mbe :logic (address-set-fix previous)
                          :exec previous)))
        (list (cons 'author author)
              (cons 'round round)
              (cons 'transactions transactions)
              (cons 'previous previous)))))