Function:
(defun nats-from-exec (a b nrev) (declare (xargs :stobjs (nrev))) (declare (xargs :guard (and (natp a) (natp b)))) (declare (xargs :guard (<= a b))) (let ((__function__ 'nats-from-exec)) (declare (ignorable __function__)) (let ((a (lnfix a)) (b (lnfix b))) (if (mbe :logic (zp (- b a)) :exec (= a b)) (nrev-fix nrev) (let ((nrev (nrev-push a nrev))) (nats-from-exec (+ 1 a) b nrev))))))