User Tools

Site Tools


jvs:cigal:manual:chapter3:mode

CIGAL Reference Manual, Chapter 3 (Functions): mode

Mode -- Get information about a variable's data and storage type

usage: modevalue = mode(varb)

MODE returns a value describing the data type of its argument, VARB. The returned value is a long integer whose low 8 bits indicate the size and type of each data element within VARB, and the upper 24 bits describe the storage type of the variable as a whole. These two bit fields meanings are described below. The capitalized words in parentheses indicate modifier words that would have been specified when this variable was originally declared (see DECLARE(2)).

 WORDSIZE -- low 8 bits of MODEVALUE:
            (octal)
        0      (0)  -  argument unspecified or an unassigned POINTER variable
        1      (1)  -  1 bit integers (BIT)
        2      (2)  -  2 bit integers (CRUMB)
        4      (4)  -  4 bit integers (NIBBLE)
        8     (10)  -  8 bit integers (BYTE) or characters (STRING)
       16     (20)  -  16 bit integers (INTEGER)
       32     (40)  -  32 bit integers (LONG)
       96    (140)  -  32 bit floating point values (REAL)
      136    (210)  -  64 bit graphics vector (VECTOR)

 VARBTYPE -- high 24 bits of MODEVALUE:
            (octal)
        0      (0)  -  argument unspecified or an unassigned POINTER variable
       16     (20)  -  single-valued number (NUMBER)
       32     (40)  -  character string (STRING)
       64    (100)  -  1-dimensional array (ARRAY)
      128    (200)  -  2-dimensional array (MATRIX)
      256    (400)  -  graphics vector (VECTOR)
      384    (600)  -  array of graphics vectors (VECTOR LIST)
      512   (1000)  -  2-dimensional array (IMAGE)
     1024   (2000)  -  3-dimensional array (SOLID)
     2080   (4040)  -  table of character strings (STRING LIST)
     4096  (10000)  -  variable is stored on the STACK memory
     8192  (20000)  -  argument is a CIGAL command

See Also:
ADDRESS(3), DECLARE(2), POINTER(3), STACK(4), VARIABLES(1)

CIGAL Home, CIGAL Manual, Functions List, Manual Help

jvs/cigal/manual/chapter3/mode.txt · Last modified: 2023/02/23 18:43 (external edit)