freenode/#lisp - IRC Chatlog
Search
2:05:08
adlai
ACTION is estimating an ETA for ECL issue 305 fixing itself in the absence of external motivation
9:23:04
decent-username
I wanted to understand how :adjustable modifies the characteristics of an array. Therefore I've read what the HyperSpec had to say, but it didn't really help me. Why would I want to use ":adjustable t" when creating an array?
9:25:33
jackdaniel
decent-username: i.e when the average case is that array will hold 4 elements but in rare occasions it needs to hold 1024 elements
9:27:21
decent-username
Because doing something like (make-array 4 :adjustable t) will still raise an error when I try to use vector-push-extend
9:27:28
jackdaniel
if you have *a lot* of small arrays then it would be a huge waste to have each of them to have 1024 size
9:28:26
decent-username
ahh, I didn't know such a function existed. I think that's the thing that led to the confusion.
9:31:38
jackdaniel
I'm still waiting for the new CL standard with left-fill-pointer, rotating arrays and conformal displacement :-)
9:34:29
decent-username
the rotating part would allow for the creating of some interesting functions.
9:42:55
p_l
any language out there that has them in standard (not to be mistaken with abuse of communication primitives to make buffers
9:54:28
no-defun-allowed
phoe: depends on the circumference of the vector and width of the cells, assuming a spiral vector
9:56:44
no-defun-allowed
phoe: oh, you wanted circular vectors, and those were for circular vectors but I said spiral for some reason
9:58:56
loke
My circular array: https://github.com/lokedhs/containers/blob/master/src/blocking-queue.lisp#L17
10:01:24
no-defun-allowed
well, the vector is circular, the circumference is one-dimensional but the circle is two-dimensional
10:02:20
loke
no-defun-allowed: No. It's a one-dimensional vector. Just because its curvature is positive doesn't mean that there are any more dimensions.
10:07:13
loke
Some interating related discussion: https://www.physicsforums.com/threads/are-all-lines-one-dimensional.602170/
10:14:21
scymtym
decent-username: VECTOR-PUSH-EXTEND can adjust the array for you, but you have to specify both, :adjustable t and :fill-pointer VALID-INDEX-OR-T when creating the array for that to work
10:19:39
scymtym
loke: i don't follow. decent-username asked why (make-array 4 :adjustable t) followed by VECTOR-PUSH-EXTEND didn't work