• Top
    • Documentation
    • Books
    • Boolean-reasoning
    • Projects
    • Debugging
    • 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
            • Abstract-syntax
            • Integer-ranges
            • Implementation-environments
            • Dynamic-semantics
            • Static-semantics
            • Grammar
            • Integer-formats
            • Types
            • Portable-ascii-identifiers
            • Values
            • Integer-operations
            • Computation-states
            • Object-designators
            • Operations
            • Errors
            • Tag-environments
            • Function-environments
              • Init-fun-env
              • Fun-info
              • Fun-info-option
              • Fun-env-extend
              • Fun-env-result
              • Fun-env-lookup
              • Fun-info-from-fundef
              • Fun-env
                • Fun-envp
                  • Fun-env-fix
                  • Fun-env-equiv
              • Character-sets
              • Flexible-array-member-removal
              • Arithmetic-operations
              • Pointer-operations
              • Bytes
              • Keywords
              • Real-operations
              • Array-operations
              • Scalar-operations
              • Structure-operations
            • Representation
            • Transformation-tools
            • Insertion-sort
            • Pack
          • Bv
          • Imp-language
          • Event-macros
          • Java
          • 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
    • Fun-env

    Fun-envp

    Recognizer for fun-env.

    Signature
    (fun-envp x) → *

    Definitions and Theorems

    Function: fun-envp

    (defun fun-envp (x)
      (declare (xargs :guard t))
      (if (atom x)
          (null x)
        (and (consp (car x))
             (identp (caar x))
             (fun-infop (cdar x))
             (or (null (cdr x))
                 (and (consp (cdr x))
                      (consp (cadr x))
                      (acl2::fast-<< (caar x) (caadr x))
                      (fun-envp (cdr x)))))))

    Theorem: booleanp-of-fun-envp

    (defthm booleanp-of-fun-envp
      (booleanp (fun-envp x)))

    Theorem: mapp-when-fun-envp

    (defthm mapp-when-fun-envp
      (implies (fun-envp x) (omap::mapp x))
      :rule-classes (:rewrite :forward-chaining))

    Theorem: fun-envp-of-tail

    (defthm fun-envp-of-tail
      (implies (fun-envp x)
               (fun-envp (omap::tail x))))

    Theorem: identp-of-head-key-when-fun-envp

    (defthm identp-of-head-key-when-fun-envp
      (implies (and (fun-envp x)
                    (not (omap::emptyp x)))
               (identp (mv-nth 0 (omap::head x)))))

    Theorem: fun-infop-of-head-val-when-fun-envp

    (defthm fun-infop-of-head-val-when-fun-envp
      (implies (and (fun-envp x)
                    (not (omap::emptyp x)))
               (fun-infop (mv-nth 1 (omap::head x)))))

    Theorem: fun-envp-of-update

    (defthm fun-envp-of-update
      (implies (and (fun-envp x)
                    (identp k)
                    (fun-infop v))
               (fun-envp (omap::update k v x))))

    Theorem: fun-envp-of-update*

    (defthm fun-envp-of-update*
      (implies (and (fun-envp x) (fun-envp y))
               (fun-envp (omap::update* x y))))

    Theorem: fun-envp-of-delete

    (defthm fun-envp-of-delete
      (implies (fun-envp x)
               (fun-envp (omap::delete k x))))

    Theorem: fun-envp-of-delete*

    (defthm fun-envp-of-delete*
      (implies (fun-envp x)
               (fun-envp (omap::delete* k x))))

    Theorem: identp-when-assoc-fun-envp-binds-free-x

    (defthm identp-when-assoc-fun-envp-binds-free-x
      (implies (and (omap::assoc k x) (fun-envp x))
               (identp k)))

    Theorem: identp-of-car-of-assoc-fun-envp

    (defthm identp-of-car-of-assoc-fun-envp
      (implies (and (fun-envp x) (omap::assoc k x))
               (identp (car (omap::assoc k x)))))

    Theorem: fun-infop-of-cdr-of-assoc-fun-envp

    (defthm fun-infop-of-cdr-of-assoc-fun-envp
      (implies (and (fun-envp x) (omap::assoc k x))
               (fun-infop (cdr (omap::assoc k x)))))

    Theorem: fun-infop-of-lookup-when-fun-envp

    (defthm fun-infop-of-lookup-when-fun-envp
      (implies (and (fun-envp x) (omap::assoc k x))
               (fun-infop (omap::lookup k x))))