Length of an array of type
(uint-array-length array) → length
Function:
(defun uint-array-length (array) (declare (xargs :guard (uint-arrayp array))) (let ((__function__ 'uint-array-length)) (declare (ignorable __function__)) (len (uint-array->elements array))))
Theorem:
(defthm posp-of-uint-array-length (b* ((length (uint-array-length array))) (posp length)) :rule-classes (:rewrite :type-prescription))
Theorem:
(defthm natp-of-uint-array-length (b* ((length (uint-array-length array))) (natp length)) :rule-classes :rewrite)
Theorem:
(defthm uint-array-length-alt-def (implies (uint-arrayp array) (equal (uint-array-length array) (value-array->length array))))
Theorem:
(defthm uint-array-length-of-uint-array-fix-array (equal (uint-array-length (uint-array-fix array)) (uint-array-length array)))
Theorem:
(defthm uint-array-length-uint-array-equiv-congruence-on-array (implies (uint-array-equiv array array-equiv) (equal (uint-array-length array) (uint-array-length array-equiv))) :rule-classes :congruence)