chickadee » generalized-arrays » make-array

make-array storage-class dimension #!optional fillprocedure

Constructs an array by allocating a storage object of the provided storage-class and dimension. If fill is provided, every value in the array is set to fill, otherwise the array is defaulted with the value as if calling (storage-class-default-element storage-class).

 
(import generalized-arrays
        test)

(test-assert "Array is filled with #f"
  (array=? #a2v((#f #f #f)
                (#f #f #f)
                (#f #f #f))
           (make-array vector-storage-class #(3 3) #f)))