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