Rename INDEX to REF or so? #936
stylewarning
started this conversation in
Ideas and Proposals
Replies: 1 comment 1 reply
-
What about doubling up on index-like accessors? Using Sometimes you want to curry over the location and other times over the structure. (map (flip vector:index my-vec) (make-list 1 30 400))
;; ===
(map (get my-vec) (make-list 1 30 400))
But its also nice to do (map (vector:index 10) (make-list vec1 vec2 vec3))
I'd favor |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Can we rename all lookup-like functions to
ref
orget
? I'm always stumped byindex
because I wonder if it's indexing into or finding the index of something. CL usesaref
,svref
,elt
,nth
, andgethash
, so they're not exactly consistent.A nice thing about
index
currently is that(index i)
is a good curried accessor.Beta Was this translation helpful? Give feedback.
All reactions