• 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
        • Soft
        • C
          • Syntax-for-tools
          • Atc
          • Language
          • Transformation-tools
            • Simpadd0
            • Splitgso
            • Constant-propagation
            • Specialize
              • Specialize-implementation
                • Param-declon-list-remove-param-by-ident
                • Specialize-fundef
                • Specialize-extdecl
                • Specialize-filepath-transunit-map
                • Specialize-extdecl-list
                • Specialize-transunit-ensemble
                • Param-declon-to-decl
                  • Specialize-transunit
                  • Ident-from-param-declon
                  • Specialize-event-generation
                  • Specialize-input-processing
              • Split-fn
              • Split-fn-when
              • Split-all-gso
              • Copy-fn
              • Rename
              • Utilities
            • Representation
            • Insertion-sort
            • Pack
          • Bv
          • Imp-language
          • Event-macros
          • Java
          • Riscv
          • Bitcoin
          • Ethereum
          • Yul
          • Zcash
          • ACL2-programming-language
          • Prime-fields
          • Json
          • Syntheto
          • File-io-light
          • Cryptography
          • Number-theory
          • Lists-light
          • Axe
          • Builtins
          • Solidity
          • Helpers
          • Htclient
          • Typed-lists-light
          • Arithmetic-light
        • X86isa
        • Axe
        • Execloader
      • Math
      • Testing-utilities
    • Specialize-implementation

    Param-declon-to-decl

    Convert a parameter declaration to a regular declaration.

    Signature
    (param-declon-to-decl paramdecl init?) → (mv success decl)
    Arguments
    paramdecl — Guard (param-declonp paramdecl).
    init? — Guard (initer-optionp init?).
    Returns
    success — Type (booleanp success).
    decl — Type (declp decl).

    Definitions and Theorems

    Function: param-declon-to-decl

    (defun param-declon-to-decl (paramdecl init?)
     (declare (xargs :guard (and (param-declonp paramdecl)
                                 (initer-optionp init?))))
     (b* (((param-declon paramdecl) paramdecl))
      (param-declor-case
       paramdecl.declor
       :nonabstract
       (mv
        t
        (make-decl-decl
          :extension nil
          :specs paramdecl.specs
          :init (cons (initdeclor paramdecl.declor.declor nil nil init?)
                      nil)))
       :otherwise (mv nil (irr-decl)))))

    Theorem: booleanp-of-param-declon-to-decl.success

    (defthm booleanp-of-param-declon-to-decl.success
      (b* (((mv ?success c$::?decl)
            (param-declon-to-decl paramdecl init?)))
        (booleanp success))
      :rule-classes :rewrite)

    Theorem: declp-of-param-declon-to-decl.decl

    (defthm declp-of-param-declon-to-decl.decl
      (b* (((mv ?success c$::?decl)
            (param-declon-to-decl paramdecl init?)))
        (declp decl))
      :rule-classes :rewrite)