User Tools


Differences

This shows you the differences between two versions of the page.

Link to this comparison view

cl:functions:row-major-aref [2019/09/14 05:00]
cl:functions:row-major-aref [2019/09/20 08:00] (current)
Line 1: Line 1:
 +====== Accessor ROW-MAJOR-AREF ======
 +
 +====Syntax====
 +  * **row-major-aref** //array index// → //​element// ​
 +  * (**setf** (**row-major-aref** //array index//) //​new-element//​)
 +
 +====Arguments and Values====
 +  * //array// - an //​[[CL:​Glossary:​array]]//​.
 +  * //index// - a //​[[CL:​Glossary:​valid array row-major index]]// for the //array//.
 +  * //​element//,​ //​new-element//​ - an //​[[CL:​Glossary:​object]]//​.
 +
 +====Description====
 +Considers //​[[CL:​Glossary:​array]]//​ as a //​[[CL:​Glossary:​vector]]//​ by viewing its //​[[CL:​Glossary:​element|elements]]//​ in row-major order, and returns the //​[[CL:​Glossary:​element]]//​ of that //​[[CL:​Glossary:​vector]]//​ which is referred to by the given //index//.
 +
 +====Examples====
 +None.
 +
 +====Side Effects====
 +None.
 +
 +====Affected By====
 +None.
 +
 +====Exceptional Situations====
 +None.
 +
 +====See Also====
 +**[[CL:​Functions:​aref|Function AREF]]**, **[[CL:​Functions:​array-row-major-index|Function ARRAY-ROW-MAJOR-INDEX]]**
 +
 +====Notes====
 +
 +<​blockquote> ​
 +(row-major-aref array index) ​
 +  ≡ ([[CL:​Functions:​aref]] ([[CL:​Functions:​make-array]] ([[CL:​Functions:​array-total-size]] array) ​
 +                      :​displaced-to array 
 +                      :​element-type ([[CL:​Functions:​array-element-type]] array)) ​
 +          index)
 +
 +([[CL:​Functions:​aref]] array i1 i2 ...) ≡ (row-major-aref array ([[CL:​Functions:​array-row-major-index]] array i1 i2))
 +</​blockquote>​
 +
 +\issue{AREF-1D}
 +\issue{ARRAY-DIMENSION-LIMIT-IMPLICATIONS:​ALL-FIXNUM}