1 % Copyright (C) 2008 Bert Burgemeister
3 % Permission is granted to copy, distribute and/or modify this
4 % document under the terms of the GNU Free Documentation License,
5 % Version 1.2 or any later version published by the Free Software
6 % Foundation; with no Invariant Sections, no Front-Cover Texts and
7 % no Back-Cover Texts. For details see file COPYING.
10 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
11 \section{Types and Classes
}
12 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
22 \kwd*
{REAL
} \OP{\VAR{lower-limit
}\DF{\kwd{\A}}\text{ }\Op{\VAR{upper-limit
}\DF{\kwd{\A}}}}\\
24 \kwd*
{RATIONAL
} \OP{\VAR{lower-limit
}\DF{\kwd{\A}}\text{ }\Op{\VAR{upper-limit
}\DF{\kwd{\A}}}}\\
26 \kwd*
{INTEGER
} \OP{\VAR{lower-limit
}\DF{\kwd{\A}}\text{ }\Op{\VAR{upper-limit
}\DF{\kwd{\A}}}}\\
28 \kwd*
{SIGNED-BYTE
} \Op{\VAR{size
}\DF{\kwd{\A}}}\\
29 \boxGOO{\kwd*
{UNSIGNED-BYTE
} \Op{\VAR{size
}\DF{\kwd{\A}}}
30 \boxGOO{\kwd*
{BIT
} }}\boxGOOcr
34 \kwd*
{RATIO
}}\boxGOOcr
35 \kwd*
{FLOAT
} \OP{\VAR{lower-limit
}\DF{\kwd{\A}}\text{ }\Op{\VAR{upper-limit
}\DF{\kwd{\A}}}}\\
37 \kwd*
{SHORT-FLOAT
} \OP{\VAR{lower-limit
}\DF{\kwd{\A}}\text{ }\Op{\VAR{upper-limit
}\DF{\kwd{\A}}}}\\
38 \kwd*
{SINGLE-FLOAT
} \OP{\VAR{lower-limit
}\DF{\kwd{\A}}\text{ }\Op{\VAR{upper-limit
}\DF{\kwd{\A}}}}\\
39 \kwd*
{DOUBLE-FLOAT
} \OP{\VAR{lower-limit
}\DF{\kwd{\A}}\text{ }\Op{\VAR{upper-limit
}\DF{\kwd{\A}}}}\\
40 \kwd*
{LONG-FLOAT
} \OP{\VAR{lower-limit
}\DF{\kwd{\A}}\text{ }\Op{\VAR{upper-limit
}\DF{\kwd{\A}}}}}}\boxGOOcr
41 \kwd*
{COMPLEX
} \Op{\VAR{type
}\DF{\kwd{\A}}}}\boxGOOcr
46 \kwd*
{CONS
} \OP{\VAR{car-type
}\DF{\kwd{\A}}\text{ }\Op{\VAR{cdr-type
}\DF{\kwd{\A}}}}\\
47 \kwd*
{SYMBOL
}\footnotemark[2]
49 \kwd*
{NULL
}}}\boxGOOcr
50 \kwd*
{ARRAY
}\footnotemark[2] \OP{\VAR{type
}\DF{\kwd{\A}}\text{ }\Op{\VAR{rank
}\DF{\kwd{\A}}\XOR(
\OPn{\VAR{dimension
}})
}}\\
52 \kwd*
{SIMPLE-ARRAY
}\footnotemark[2] \OP{\VAR{type
}\DF{\kwd{\A}}\text{ }\Op{\VAR{rank
}\DF{\kwd{\A}}\XOR(
\OPn{\VAR{dimension
}})
}}\\
54 \kwd*
{VECTOR
}\footnotemark[2] \OP{\VAR{type
}\DF{\kwd{\A}}\text{ }\Op{\VAR{size
}\DF{\kwd{\A}}}}\\
56 \kwd*
{BIT-VECTOR
}\footnotemark[2] \Op{\VAR{size
}\DF{\kwd{\A}}}\\
58 \kwd*
{SIMPLE-BIT-VECTOR
} \Op{\VAR{size
}\DF{\kwd{\A}}}}\boxGOOcr
59 \kwd*
{STRING
}\footnotemark[2] \Op{\VAR{size
}\DF{\kwd{\A}}}\\
61 \kwd*
{SIMPLE-STRING
} \Op{\VAR{size
}\DF{\kwd{\A}}}\\
63 \kwd*
{BASE-STRING
}\footnotemark[2] \Op{\VAR{size
}\DF{\kwd{\A}}}\\
65 \kwd*
{SIMPLE-BASE-STRING
} \Op{\VAR{size
}\DF{\kwd{\A}}}}}}\boxGOOcr
66 \kwd*
{SIMPLE-VECTOR
} \Op{\VAR{size
}\DF{\kwd{\A}}}}}\boxGOOcr
67 \kwd*
{VECTOR
} \OP{\VAR{type
}\DF{\kwd{\A}}\text{ }\Op{\VAR{size
}\DF{\kwd{\A}}}}\\
69 \kwd*
{STRING
} \Op{\VAR{size
}\DF{\kwd{\A}}}
71 \kwd*
{BASE-STRING
} \Op{\VAR{size
}\DF{\kwd{\A}}}}\boxGOOcr
72 \kwd*
{BIT-VECTOR
} \Op{\VAR{size
}\DF{\kwd{\A}}}}}}\boxGOOcr
73 \kwd*
{ARRAY
} \OP{\VAR{type
}\DF{\kwd{\A}}\text{ }\Op{\VAR{rank
}\DF{\kwd{\A}}\XOR(
\OPn{\VAR{dimension
}})
}}\\
75 \kwd*
{SIMPLE-ARRAY
} \OP{\VAR{type
}\DF{\kwd{\A}}\text{ }\Op{\VAR{rank
}\DF{\kwd{\A}}\XOR(
\OPn{\VAR{dimension
}})
}}
81 \kwd*
{STANDARD-CHAR
}}\boxGOOcr
82 \kwd*
{EXTENDED-CHAR
}}\boxGOOcr
86 \kwd*
{TWO-WAY-STREAM
};\>
87 \kwd*
{SYNONYM-STREAM
};\\
88 \kwd*
{STRING-STREAM
};\>
89 \kwd*
{BROADCAST-STREAM
};\>
91 \kwd*
{CONCATENATED-STREAM
}}\boxGOOcr
94 \kwd*
{LOGICAL-PATHNAME
}}\boxGOOcr
98 \kwd*
{BOOLEAN
}}\boxGOOcr
99 \kwd*
{FUNCTION
} \OP{\VAR{arg-types
}\Op{\VAR{value-types
}}}\\
101 \kwd*
{GENERIC-FUNCTION
}
102 \boxGOO{\kwd*
{STANDARD-GENERIC-FUNCTION
}}\boxGOOcr
103 \kwd*
{COMPILED-FUNCTION
}}\boxGOOcr
104 \kwd*
{STANDARD-OBJECT
}
108 \kwd*
{STANDARD-CLASS
};\>
109 \kwd*
{BUILT-IN-CLASS
};\\
110 \kwd*
{STRUCTURE-CLASS
}}\boxGOOcr
111 \kwd*
{METHOD
}\footnotemark[2]
113 \kwd*
{STANDARD-METHOD
}}}\boxGOOcr
116 \kwd*
{STRUCTURE-OBJECT
};\>
119 \kwd*
{RANDOM-STATE
};\>
122 \kwd*
{METHOD-COMBINATION
}}}
123 \end{center
}\vspace{-
1em
}
124 {\footnotesize\footnotemark[2]For supertypes of this
125 type look for the instance without a
\footnotemark[2].
}\\
126 {\footnotesize As a type argument,
\kwd{\A} means no restriction.
\index{*@
\A}}
128 \caption{Data Types.
}%
131 For any class, there is always a corresponding type of the same name.
135 \IT{(
\FU*
{TYPEP
} \VAR{foo
} \VAR{type
} \Op{\VAR{environment
}\DF{\NIL}})
}
137 Return
\retval{\T} if
\VAR{foo
} is of
\VAR{type
}.
140 \IT{(
\FU*
{SUBTYPEP
} \VAR{type-a
} \VAR{type-b
}
141 \Op{\VAR{environment
}})
}
143 Return
\retval{\T} if
\VAR{type-a
} is a recognizable subtype of
144 \VAR{type-b
}, and
\retvalii{\NIL} if the relationship could not be
148 \IT{(
\SO*
{THE
} \NEV{\VAR{type
}} \VAR{form
})
}
150 Return
\retval{values
} of
\VAR{form
} which are declared to be of
154 \IT{(
\FU*
{COERCE
} \VAR{object
} \VAR{type
})
}
156 Coerce
\VAR{object
} into
\VAR{type
}.
159 \IT{(
\MC*
{TYPECASE
} \VAR{foo
} \OPn{(
\NEV{\VAR{type
}} \PROGN{\VAR{a-form
}})
}
160 \OP{(
\xorGOO{\kwd*
{OTHERWISE
}\\
161 \T}{\
}} \PROGN{\VAR{b-form
}\DF{\NIL}})
})
}
163 Return
\retval{values of the
\VAR{a-form
}s
} whose
\VAR{type
} is
164 \VAR{foo
} of. Return
\retval{values of
\VAR{b-form
}s
} if no
168 \IT{(
\xorGOO{\MC*
{CTYPECASE
}\\
169 \MC*
{ETYPECASE
}}{\
}} \VAR{foo
} \OPn{(
\NEV{\VAR{type
}}
170 \PROGN{\VAR{form
}})
})
}
172 Return
\retval{values of the
\VAR{form
}s
} whose
\VAR{type
} is
173 \VAR{foo
} of. Signal correctable/non-correctable error, respectively
174 if no
\VAR{type
} matches.
177 \IT{(
\FU*
{TYPE-OF
} \VAR{foo
})
}
179 \retval{Type of
\VAR{foo
}}.
182 \IT{(
\kwd*
{CHECK-TYPE
} \VAR{place
} \VAR{type
} \Op{\VAR{string
}})
}
184 Return
\retval{\NIL} and signal correctable
\kwd{type-error
} if
\VAR{place
} is
188 \IT{(
\FU*
{STREAM-ELEMENT-TYPE
} \VAR{stream
})
}
190 Return
\retval{type
} of
\VAR{stream
} objects.
193 \IT{(
\FU*
{ARRAY-ELEMENT-TYPE
} \VAR{array
})
}
195 Element
\retval{type
} \VAR{array
} can hold.
198 \IT{(
\FU*
{UPGRADED-ARRAY-ELEMENT-TYPE
} \VAR{type
}
199 \Op{\VAR{environment
}\DF{\NIL}})
}
201 \retval{Element type
} of most specialized array capable of holding
202 elements of
\VAR{type
}.
205 \IT{(
\MC*
{DEFTYPE
} \VAR{foo
} (
\OPn{\VAR{macro-$
\lambda$
}})
206 \OPn{(
\kwd{declare
} \OPn{\NEV{\VAR{decl
}}})
} \Op{\NEV{\VAR{doc
}}}
209 Define type
\retval{\VAR{foo
}} which when referenced as (
\VAR{foo
}
210 \OPn{\NEV{\VAR{arg
}}}) applies expanded
\VAR{form
}s to
\VAR{arg
}s
211 returning the new type. For (
\OPn{\VAR{macro-$
\lambda$
}}) see
212 p.~
\pageref{section:Macros
} but with default value of
\kwd{\A}
213 instead of
\NIL.
\VAR{form
}s are enclosed in an implicit
\SO{block
} \VAR{foo
}.
216 \IT{\arrGOO{(
\kwd*
{EQL
} \VAR{foo
})\\
217 (
\kwd*
{MEMBER
} \OPn{\VAR{foo
}})
}{.
}}
219 Specifier for a type comprising
\VAR{foo
} or
\VAR{foo
}s.
222 \IT{(
\kwd*
{SATISFIES
} \VAR{predicate
})
}
224 Type specifier for all objects satisfying
\VAR{predicate
}.
227 \IT{(
\kwd*
{MOD
} \VAR{n
})
}
229 Type specifier for all non-negative integers $<n$.
232 \IT{(
\kwd*
{NOT
} \VAR{type
})
}
237 \IT{(
\kwd*
{AND
} \OPn{\VAR{type
}}\DF{\T})
}
239 Type specifier for intersection of
\VAR{type
}s.
242 \IT{(
\kwd*
{OR
} \OPn{\VAR{type
}}\DF{\NIL})
}
244 Type specifier for union of
\VAR{type
}s.
247 \IT{(
\kwd*
{VALUES
} \OPn{\VAR{type
}} \OP{\OPn{\kwd{\&optional
} \VAR{type
}}
248 \Op{\kwd{\&rest
} \VAR{other-args
}}})
}
250 Type specifier for multiple values.
259 %%% TeX-master: "clqr"