User Tools


Differences

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

Link to this comparison view

cl:types:simple-array [2017/05/01 21:00] (current)
Line 1: Line 1:
 +====== Type SIMPLE-ARRAY ======
 +
 +====Supertypes====
 +**simple-array**,​ **[[CL:​Types:​array]]**,​ **[[CL:​Types:​t]]**
 +
 +====Description====
 +The //​[[CL:​Glossary:​type]]//​ of an //​[[CL:​Glossary:​array]]//​ that is not displaced to another //​[[CL:​Glossary:​array]]//,​ has no //​[[CL:​Glossary:​fill pointer]]//,​ and is not //​[[CL:​Glossary:​expressly adjustable]]//​ is a subtype of **[[CL:​Types:​simple-array]]**. The concept of a //​[[CL:​Glossary:​simple array]]// exists to allow the implementation to use a specialized representation and to allow the user to declare that certain values will always be //​[[CL:​Glossary:​simple array|simple arrays]]//.
 +
 +The //​[[CL:​Glossary:​type|types]]//​ **[[CL:​Types:​simple-vector]]**,​ **[[CL:​Types:​simple-string]]**,​ and **[[CL:​Types:​simple-bit-vector]]** are //​[[CL:​Glossary:​disjoint]]//​ subtypes of **[[CL:​Types:​simple-array]]**,​ for they respectively mean ''​(simple-array t ([[CL:​Types:​wildcard|*]]))'',​ the union of all ''​(simple-array c ([[CL:​Types:​wildcard|*]]))''​ for any ''​c''​ being a subtype of **[[CL:​Types:​character]]**,​ and ''​(simple-array [[CL:​Types:​bit]] ([[CL:​Types:​wildcard|*]]))''​.
 +
 +====Compound Type Specifier Kind====
 +Specializing.
 +
 +====Compound Type Specifier Syntax====
 +//​**simple-array** //​[{element-type | **[[CL:​Types:​wildcard|*]]**} [dimension-spec]]////​
 +
 +''​dimension-spec''​ := ''​rank | **[[CL:​Types:​wildcard|*]]** | ({dimension | **[[CL:​Types:​wildcard|*]]**}*)''​
 +
 +====Compound Type Specifier Arguments====
 +//​dimension//​ - a //​[[CL:​Glossary:​valid array dimension]]//​.
 +//​element-type//​ - a //​[[CL:​Glossary:​type specifier]]//​.
 +//rank// - a non-negative //​[[CL:​Glossary:​fixnum]]//​.
 +
 +====Compound Type Specifier Description====
 +This //​[[CL:​Glossary:​compound type specifier]]//​ is treated exactly as the corresponding //​[[CL:​Glossary:​compound type specifier]]//​ for //​[[CL:​Glossary:​type]]//​ **[[CL:​Types:​array]]** would be treated, except that the set is further constrained to include only //​[[CL:​Glossary:​simple array|simple arrays]]//.
 +
 +====Notes====
 +It is //​[[CL:​Glossary:​implementation-dependent]]//​ whether //​[[CL:​Glossary:​displaced array|displaced arrays]]//, //​[[CL:​Glossary:​vector|vectors]]//​ with //​[[CL:​Glossary:​fill pointer|fill pointers]]//,​ or arrays that are //​[[CL:​Glossary:​actually adjustable]]//​ are //​[[CL:​Glossary:​simple arrays]]//.
 +
 +''​(simple-array [[CL:​Types:​wildcard|*]])''​ refers to all //​[[CL:​Glossary:​simple array|simple arrays]]// regardless of element type, ''​(simple-array //​type-specifier//​)''​ refers only to those //​[[CL:​Glossary:​simple array|simple arrays]]// that can result from giving //​type-specifier//​ as the **'':​element-type''​** argument to **[[CL:​Functions:​make-array]]**.
 +
 +\issue{ARRAY-DIMENSION-IMPLICATIONS:​ALL-FIXNUM} \issue{ARRAY-TYPE-ELEMENT-TYPE-SEMANTICS:​UNIFY-UPGRADING}