• Top
    • Documentation
    • Books
    • Boolean-reasoning
    • Projects
      • Apt
      • Zfc
      • Acre
      • Milawa
      • Smtlink
      • Abnf
      • Vwsim
      • Isar
      • Wp-gen
      • Dimacs-reader
      • Pfcs
      • Legacy-defrstobj
      • C
        • Syntax-for-tools
        • Atc
        • Transformation-tools
        • Language
        • Representation
          • Representation-of-integer-operations
          • Atc-arrays
            • Atc-def-integer-arrays
            • Ushort-array-write
            • Ushort-array-integer-write
            • Ulong-array-integer-write
            • Ullong-array-write
            • Ullong-array-integer-write
            • Uchar-array-integer-write
            • Sshort-array-write
            • Sshort-array-integer-write
            • Slong-array-integer-write
            • Sllong-array-write
            • Sllong-array-integer-write
            • Schar-array-integer-write
            • Ulong-array-write
            • Uchar-array-write
            • Slong-array-write
            • Schar-array-write
            • Uint-array-write
            • Uint-array-integer-write
            • Sint-array-write
            • Sint-array-integer-write
            • Ushort-array
            • Ullong-array
            • Sshort-array
            • Sllong-array
            • Ulong-array
            • Uint-array
            • Uchar-array
            • Slong-array
            • Sint-array
              • Sint-array-fix
              • Sint-array-equiv
              • Make-sint-array
              • Sint-arrayp
              • Sint-array->elements
                • Sint-array->elemtype
                • Change-sint-array
              • Schar-array
              • Ushort-array-integer-read
              • Ushort-array-integer-index-okp
              • Ullong-array-integer-read
              • Ullong-array-integer-index-okp
              • Sshort-array-integer-read
              • Sshort-array-integer-index-okp
              • Sllong-array-integer-read
              • Sllong-array-integer-index-okp
              • Ulong-array-integer-read
              • Ulong-array-integer-index-okp
              • Ullong-array-read
              • Uint-array-integer-read
              • Uint-array-integer-index-okp
              • Uchar-array-integer-read
              • Uchar-array-integer-index-okp
              • Slong-array-integer-read
              • Slong-array-integer-index-okp
              • Sllong-array-read
              • Sint-array-integer-read
              • Sint-array-integer-index-okp
              • Schar-array-integer-read
              • Schar-array-integer-index-okp
              • Ushort-array-read
              • Ushort-array-index-okp
              • Ulong-array-read
              • Ulong-array-index-okp
              • Ullong-array-index-okp
              • Uint-array-read
              • Uchar-array-read
              • Uchar-array-index-okp
              • Sshort-array-read
              • Sshort-array-index-okp
              • Slong-array-read
              • Slong-array-index-okp
              • Sllong-array-index-okp
              • Sint-array-read
              • Schar-array-read
              • Schar-array-index-okp
              • Uint-array-index-okp
              • Sint-array-index-okp
              • Ushort-array-of
              • Ullong-array-of
              • Uchar-array-length
              • Sshort-array-of
              • Sllong-array-of
              • Ulong-array-of
              • Uint-array-of
              • Uchar-array-of
              • Slong-array-of
              • Sint-array-of
              • Schar-array-of
              • Ushort-array-length
              • Ulong-array-length
              • Ullong-array-length
              • Sshort-array-length
              • Sllong-array-length
              • Uint-array-length
              • Slong-array-length
              • Sint-array-length
              • Schar-array-length
              • Atc-def-integer-arrays-loop
            • Representation-of-integers
            • Representation-of-integer-conversions
            • Pointed-integers
            • Shallow-deep-embedding-relation
          • Insertion-sort
          • Pack
        • Proof-checker-array
        • Soft
        • Farray
        • Rp-rewriter
        • Instant-runoff-voting
        • Imp-language
        • Sidekick
        • Ethereum
        • Leftist-trees
        • Java
        • Riscv
        • Taspi
        • Bitcoin
        • Zcash
        • Des
        • X86isa
        • Sha-2
        • Yul
        • Proof-checker-itp13
        • Regex
        • ACL2-programming-language
        • Json
        • Jfkr
        • Equational
        • Cryptography
        • Axe
        • Poseidon
        • Where-do-i-place-my-book
        • Aleo
        • Bigmems
        • Builtins
        • Execloader
        • Solidity
        • Paco
        • Concurrent-programs
        • Bls12-377-curves
      • Debugging
      • Community
      • Std
      • Proof-automation
      • Macro-libraries
      • ACL2
      • Interfacing-tools
      • Hardware-verification
      • Software-verification
      • Math
      • Testing-utilities
    • Sint-array

    Sint-array->elements

    Get the elements field from a sint-array.

    Signature
    (sint-array->elements x) → elements
    Arguments
    x — Guard (sint-arrayp x).
    Returns
    elements — Type (sint-listp elements).

    This is an ordinary field accessor created by fty::defprod.

    Definitions and Theorems

    Function: sint-array->elements$inline

    (defun sint-array->elements$inline (x)
      (declare (xargs :guard (sint-arrayp x)))
      (declare (xargs :guard t))
      (let ((__function__ 'sint-array->elements))
        (declare (ignorable __function__))
        (mbe :logic
             (b* ((x (and t x))
                  (elemtype (type-fix (std::da-nth 0 (cdr x))))
                  (elements (sint-list-fix (std::da-nth 1 (cdr x)))))
               (if (consp elements)
                   elements
                 (list (sint-from-integer 0))))
             :exec (std::da-nth 1 (cdr x)))))

    Theorem: sint-listp-of-sint-array->elements

    (defthm sint-listp-of-sint-array->elements
      (b* ((elements (sint-array->elements$inline x)))
        (sint-listp elements))
      :rule-classes :rewrite)

    Theorem: sint-array->elements$inline-of-sint-array-fix-x

    (defthm sint-array->elements$inline-of-sint-array-fix-x
      (equal (sint-array->elements$inline (sint-array-fix x))
             (sint-array->elements$inline x)))

    Theorem: sint-array->elements$inline-sint-array-equiv-congruence-on-x

    (defthm sint-array->elements$inline-sint-array-equiv-congruence-on-x
      (implies (sint-array-equiv x x-equiv)
               (equal (sint-array->elements$inline x)
                      (sint-array->elements$inline x-equiv)))
      :rule-classes :congruence)