National Institute of Advanced Industrial Science and Technology (AIST) This page is a page of the former research institute. We stopped updating on March 31.2001.
E-mail to webmaster (Japanese) E-mail to webmaster (English)
next up previous contents index
Next: Forms and Evaluation Up: Data Types Previous: Class Hierarchy

Type Specifier

Though EusLisp does not have the  deftype special form, type names are used in declarations and functions requesting to specify the type of results or contents, as in coerce, map, concatenate, make-array, etc. Usually, class names can be used as type specifiers, as in (concatenate cons "ab" "cd") = (97 98 99 100), where Common Lisp uses (quote list) instead of cons.

As EusLisp does not have classes to represent numbers, types for numbers need to be given by keywords.  :integer,  integer,  :int,  fixnum, or  :fixnum is used to represent the integer type,  :float or  float, the floating point number type. As the  element-type argument of  make-array,  :character,  character,  :byte, and  byte are recognized to make strings. Low level functions such as  defcstruct,  sys:peek, and  sys:poke, also recognize  :character,  character,  :byte, or  byte for the byte access, and  :short or  short for short word access. In any cases, keywords are preferable to lisp package symbols with the same pname.



Hirofumi Nakagaki
Fri Mar 22 12:46:38 JST 1996