• Top
    • Documentation
    • Books
    • Boolean-reasoning
    • Projects
    • Debugging
    • Community
    • Std
    • Proof-automation
    • Macro-libraries
    • ACL2
    • Interfacing-tools
    • Hardware-verification
    • Software-verification
      • Kestrel-books
        • Crypto-hdwallet
        • Apt
        • Error-checking
        • Fty-extensions
        • Isar
        • Kestrel-utilities
        • Set
        • C
          • Syntax-for-tools
          • Atc
          • Transformation-tools
            • Simpadd0
              • Simpadd0-dirdeclor
              • Simpadd0-implementation
                • Simpadd0-event-generation
                  • Simpadd0-exprs/decls/stmts
                  • Simpadd0-expr-binary
                  • Simpadd0-fundef
                  • Simpadd0-filepath-transunit-map
                  • Simpadd0-transunit-ensemble
                  • Simpadd0-transunit
                  • Simpadd0-extdecl-list
                    • Simpadd0-extdecl
                    • Simpadd0-code-ensemble
                    • Simpadd0-gen-everything
                  • Simpadd0-process-inputs-and-gen-everything
                  • Simpadd0-fn
                  • Simpadd0-input-processing
                  • Simpadd0-macro-definition
                • Simpadd0-declor
                • Simpadd0-initdeclor
                • Simpadd0-initdeclor-list
                • Simpadd0-decl
                • Simpadd0-comp-stmt
                • Simpadd0-param-declor
                • Simpadd0-param-declon-list
                • Simpadd0-param-declon
                • Simpadd0-expr-option
                • Simpadd0-struct-declor-list
                • Simpadd0-struct-declon-list
                • Simpadd0-dirabsdeclor-option
                • Simpadd0-desiniter-list
                • Simpadd0-struni-spec
                • Simpadd0-struct-declor
                • Simpadd0-struct-declon
                • Simpadd0-statassert
                • Simpadd0-spec/qual-list
                • Simpadd0-spec/qual
                • Simpadd0-genassoc-list
                • Simpadd0-dirabsdeclor
                • Simpadd0-desiniter
                • Simpadd0-designor-list
                • Simpadd0-decl-spec-list
                • Simpadd0-const-expr-option
                • Simpadd0-align-spec
                • Simpadd0-absdeclor-option
                • Simpadd0-type-spec
                • Simpadd0-tyname
                • Simpadd0-member-designor
                • Simpadd0-initer-option
                • Simpadd0-initer
                • Simpadd0-genassoc
                • Simpadd0-expr-list
                • Simpadd0-enumer-list
                • Simpadd0-enumer
                • Simpadd0-enum-spec
                • Simpadd0-designor
                • Simpadd0-declor-option
                • Simpadd0-decl-spec
                • Simpadd0-decl-list
                • Simpadd0-const-expr
                • Simpadd0-block-item-list
                • Simpadd0-block-item
                • Simpadd0-absdeclor
                • Simpadd0-stmt
                • Simpadd0-label
                • Simpadd0-expr
              • Proof-generation
              • Split-gso
              • Wrap-fn
              • Constant-propagation
              • Specialize
              • Split-fn
              • Split-fn-when
              • Split-all-gso
              • Copy-fn
              • Variables-in-computation-states
              • Rename
              • Utilities
              • Proof-generation-theorems
              • Input-processing
            • Language
            • Representation
            • Insertion-sort
            • Pack
          • 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
    • Simpadd0-event-generation

    Simpadd0-extdecl-list

    Transform a list of external declarations.

    Signature
    (simpadd0-extdecl-list extdecls gin) → (mv new-extdecls gout)
    Arguments
    extdecls — Guard (extdecl-listp extdecls).
    gin — Guard (ginp gin).
    Returns
    new-extdecls — Type (extdecl-listp new-extdecls).
    gout — Type (goutp gout).

    Definitions and Theorems

    Function: simpadd0-extdecl-list

    (defun simpadd0-extdecl-list (extdecls gin)
     (declare (xargs :guard (and (extdecl-listp extdecls)
                                 (ginp gin))))
     (declare (xargs :guard (and (extdecl-list-unambp extdecls)
                                 (extdecl-list-annop extdecls))))
     (let ((__function__ 'simpadd0-extdecl-list))
      (declare (ignorable __function__))
      (b*
       (((gin gin) gin)
        ((when (endp extdecls))
         (mv nil (gout-no-thm gin)))
        ((mv new-edecl (gout gout-edecl))
         (simpadd0-extdecl (car extdecls) gin))
        (gin (gin-update gin gout-edecl))
        ((mv new-edecls (gout gout-edecls))
         (simpadd0-extdecl-list (cdr extdecls)
                                (change-gin gin
                                            :vartys gout-edecl.vartys)))
        (gin (gin-update gin gout-edecls)))
       (mv (cons new-edecl new-edecls)
           (change-gout (gout-no-thm gin)
                        :vartys gout-edecls.vartys)))))

    Theorem: extdecl-listp-of-simpadd0-extdecl-list.new-extdecls

    (defthm extdecl-listp-of-simpadd0-extdecl-list.new-extdecls
      (b* (((mv ?new-extdecls ?gout)
            (simpadd0-extdecl-list extdecls gin)))
        (extdecl-listp new-extdecls))
      :rule-classes :rewrite)

    Theorem: goutp-of-simpadd0-extdecl-list.gout

    (defthm goutp-of-simpadd0-extdecl-list.gout
      (b* (((mv ?new-extdecls ?gout)
            (simpadd0-extdecl-list extdecls gin)))
        (goutp gout))
      :rule-classes :rewrite)

    Theorem: extdecl-list-unambp-of-simpadd0-extdecl-list

    (defthm extdecl-list-unambp-of-simpadd0-extdecl-list
      (b* (((mv ?new-extdecls ?gout)
            (simpadd0-extdecl-list extdecls gin)))
        (extdecl-list-unambp new-extdecls)))

    Theorem: extdecl-list-annop-of-simpadd0-extdecl-list

    (defthm extdecl-list-annop-of-simpadd0-extdecl-list
      (implies (and (extdecl-list-unambp extdecls)
                    (extdecl-list-annop extdecls))
               (b* (((mv ?new-extdecls ?gout)
                     (simpadd0-extdecl-list extdecls gin)))
                 (extdecl-list-annop new-extdecls))))

    Theorem: extdecl-list-aidentp-of-simpadd0-extdecl-list

    (defthm extdecl-list-aidentp-of-simpadd0-extdecl-list
      (implies (and (extdecl-list-unambp extdecls)
                    (extdecl-list-aidentp extdecls gcc))
               (b* (((mv ?new-extdecls ?gout)
                     (simpadd0-extdecl-list extdecls gin)))
                 (extdecl-list-aidentp new-extdecls gcc))))

    Theorem: simpadd0-extdecl-list-of-extdecl-list-fix-extdecls

    (defthm simpadd0-extdecl-list-of-extdecl-list-fix-extdecls
      (equal (simpadd0-extdecl-list (extdecl-list-fix extdecls)
                                    gin)
             (simpadd0-extdecl-list extdecls gin)))

    Theorem: simpadd0-extdecl-list-extdecl-list-equiv-congruence-on-extdecls

    (defthm
        simpadd0-extdecl-list-extdecl-list-equiv-congruence-on-extdecls
      (implies (c$::extdecl-list-equiv extdecls extdecls-equiv)
               (equal (simpadd0-extdecl-list extdecls gin)
                      (simpadd0-extdecl-list extdecls-equiv gin)))
      :rule-classes :congruence)

    Theorem: simpadd0-extdecl-list-of-gin-fix-gin

    (defthm simpadd0-extdecl-list-of-gin-fix-gin
      (equal (simpadd0-extdecl-list extdecls (gin-fix gin))
             (simpadd0-extdecl-list extdecls gin)))

    Theorem: simpadd0-extdecl-list-gin-equiv-congruence-on-gin

    (defthm simpadd0-extdecl-list-gin-equiv-congruence-on-gin
      (implies (gin-equiv gin gin-equiv)
               (equal (simpadd0-extdecl-list extdecls gin)
                      (simpadd0-extdecl-list extdecls gin-equiv)))
      :rule-classes :congruence)