Function: hypb:map-vector

hypb:map-vector is a byte-compiled function defined in hypb.el.

Signature

(hypb:map-vector FUNC OBJECT)

Documentation

Return list of results of application of FUNC to each element of OBJECT.

OBJECT should be a vector or byte-code object.

Source Code

;; Defined in ~/.emacs.d/elpa/hyperbole-20260414.325/hypb.el
(defun hypb:map-vector (func object)
  "Return list of results of application of FUNC to each element of OBJECT.
OBJECT should be a vector or `byte-code' object."
  (unless (or (vectorp object) (byte-code-function-p object))
    (error "(hypb:map-vector): Second argument must be a vector or byte-code object"))
  (let ((end (length object))
	(i 0)
	(result))
    (while (< i end)
      (setq result (cons (funcall func (aref object i)) result)
	    i (1+ i)))
    (nreverse result)))