Nyquist / XLISP 2.0 -
Contents |
Tutorials |
Examples |
Reference
Table of Contents
- Manuals
- Reference
XLISP 2.0 Manual
Back to top
XLISP Object System
Back to top
Symbols
- + - the most recent input expression
- ++ - the next to the last input expression
- +++ - the second to the last input expression
- * - the result of the previously evaluated expression
- ** - the result of the next to the last evaluated expression
- *** - the result of the second to the last evaluated expression
- - - the expression currently being evaluated
Back to top
Evaluation Functions
Back to top
Symbol Functions
- Constructors
- Accessors
- Assignment
- set - set the value of a symbol
- setq - set the [quoted] value of a symbol
- psetq - parallel version of setq
- setf - set the value of a field
- Utilities
- incf - increment a variable
- decf - decrement a variable
Back to top
Array Functions
- Constructors
- Acessors
- aref - get the nth element of an array
- Predicate
- Utilities
- length - find the length of a list, vector or string
- hash - compute the hash index for a symbol
Back to top
List Functions
- Constructors
- cons - construct a new list node
- list - create a list of values
- Accessors
- Predicates
- consp - is this a non-empty list?
- listp - is this an empty or non-empty list?
- null - is this an empty list?
- List Functions
- append - append lists
- reverse - reverse a list
- member - find an expression in a list
- length - find the length of a list, vector or string
- subst - substitute expressions
- Association Lists
- assoc - find an expression in an a-list
- sublis - substitute with an a-list
- Property Lists
- get - get the value of a property
- putprop - put a property onto a property list
- remprop - remove a property from a property list
- Mapping
- mapc - apply function to successive cars
- mapcar - apply function to successive cars
- mapl - apply function to successive cdrs
- maplist - apply function to successive cdrs
- Lists as Stack
- push - push a value to the front of a list
- pop - pop a value from the front of a list
- Lists as Sets
- union - compute the union of two lists
- intersection - compute the intersection of two lists
- set-difference - compute the set-difference of two lists
- subsetp - test if a list is a subset of another list
- Non-destructive List Functions
- Destructive List Functions
- rplaca - replace the car of a list node
- rplacd - replace the cdr of a list node
- nconc - destructively concatenate lists
- delete - delete elements from a list
- delete-if - delete elements that pass test
- delete-if-not - delete elements that fail test
- sort - sort a list
Back to top
Predicate Functions
- Predicates
- atom - is this an atom?
- symbolp - is this a symbol?
- boundp - is a variable value bound to this symbol?
- fboundp - is a function value bound to this symbol?
- keywordp - is this a keyword?
- numberp - is this a number?
- plusp - is this number positive?
- minusp - is this number negative?
- zerop - is this number zero?
- integerp - is this number an integer?
- evenp - is this integer even?
- oddp - is this integer odd?
- floatp - is this number a float?
- null - is this an empty list?
- consp - is this a non-empty list?
- listp - is this a list?
- endp - is this the end of a list?
- stringp - is this a string?
- characterp - is this a character?
- arrayp - is this an array?
- streamp - is this a stream?
- filep - is this a file?
- objectp - is this an object?
- soundp - is this a Nyquist sound?
- bigendianp - is this a bigendian machine?
- Comparison
- eq - are the expressions identical?
- eql - are the expressions identical?
- equal - are the expressions equal?
- Boolean
Back to top
Control Constructs
- Logical
- and - the logical AND of a list of expressions
- or - the logical OR of a list of expressions
- Conditional
- if - evaluate expressions conditionally
- when - evaluate only when a condition is true
- unless - evaluate only when a condition is false
- cond - evaluate conditionally
- case - select by case
- Binding
- let - create local bindings
- let* - let with sequential binding
- flet - create local functions
- labels - flet with recursive functions
- macrolet - create local macros
- Non-local Exits
- Looping Constructs
- loop - basic looping form
- do - loop while the termination test is NIL
- do* - 'do' loop with sequential binding
- dolist - loop through a list
- dotimes - loop from zero to n-1
- while - standard 'while' loop
- The Program Feature
- prog - the program feature
- prog* - 'prog' with sequential binding
- block - named block
- return - cause a prog construct to return a value
- return-from - return from a named block
- tagbody - block with labels
- go - go to a tag within a tagbody or prog
- progv - dynamically bind symbols
- prog1 - return the value of the first expression
- prog2 - return the value of the second expression
- progn - return the value of the last expression
Back to top
Debugging and Error Handling
- trace - add a function to the trace list
- untrace - remove a function from the trace list
- error - signal a non-correctable error
- cerror - signal a correctable error
- break - enter a break loop
- clean-up - clean-up after an error
- top-level - clean-up after an error and return to the top level
- continue - continue from a correctable error
- errset - trap errors
- baktrace - print n levels of trace back information
- evalhook - evaluate with hooks
- profile - turn profiling on or off
Back to top
Arithmetic Functions
- Integer and Floating Point - error if not a number
- truncate - truncates a floating point number to an integer
- float - converts an integer to a floating point number
- + - add one or several numbers
- − - negate a single number or subtract one or several numbers
- * - multiply one or several numbers
- / - get the reciprocal of a single number or divide several numbers
- 1+ - increment a number by one
- 1− - decrement a number by one
- min - the smallest of one or several numbers
- max - the largest of one or several numbers
- abs - the absolute value of a number
- asin - compute the arcsine of a number
- acos - compute the arccosine of a number
- atan - compute the arctangent of a number
- power - compute 'x' to the 'y' power
- interpolate - compute the 'y' coordinate corresponding to 'x'
- Comparison - error if not a number
- < - test for less than
- <= - test for less than or equal to
- = - test for equal to
- /= - test for not equal to
- >= - test for greater than or equal to
- > - test for greater than
- Floating Point - error if not a floating point number
- sin - compute the sine of a floating-point number
- cos - compute the cosine of a floating-point number
- tan - compute the tangent of a floating-point number
- expt - compute x to the y power
- exp - compute e to the x power
- exp - compute the natural logarithm of a floating-point number
- sqrt - compute the square root of a floating-point number
- Integer - error if not an integer number
- gcd - compute the greatest common divisor
- logand - compute the bitwise 'and' of one or several numbers
- logior - compute the bitwise 'inclusive or' of one or several numbers
- logxor - compute the bitwise 'exclusive or' of one or several numbers
- lognot - compute the bitwise 'not' of an number
- rem - remainder of one or several integer numbers
- Random Numbers
- random - compute an integer random number between 0 and n-1 inclusive
- rrandom - compute a floating point random number between 0 and 1 inclusive
- real-random - compute a floating point random number in an arbitrary range
Back to top
String Functions
- String Functions
- string - make a string from a character or an integer ASCII value
- strcat - concatenate strings
- subseq - extract a substring
- length - find the length of a list, vector or string
- string-search - search for a pattern in a string
- Trimming
- Case Conversion
- Case-sensitive Comparison
- string< - test for less than in ASCII ordering
- string<= - test for less than or equal to in ASCII ordering
- string= - test for equal to in ASCII ordering
- string/= - test for not equal to in ASCII ordering
- string>= - test for greater than or equal to in ASCII ordering
- string> - test for greater than in ASCII ordering
- Case-insensitive Comparison
Back to top
Character Functions
- Character Functions
- char - extract a character from a string
- char-code - get the ASCII code of a character
- code-char - get the character with a specified ASCII code
- digit-char - convert a digit weight to a digit
- char-int - convert a character to an integer
- int-char - convert an integer to a character
- General Predicate - all data types
- Character Predicates - error if not a character
- Case Conversion
- Case-sensitive Comparison
- char< - test for less than in ASCII ordering
- char<= - test for less than or equal to in ASCII ordering
- char= - test for equal to in ASCII ordering
- char/= - test for not equal to in ASCII ordering
- char>= - test for greater than or equal to in ASCII ordering
- char> - test for greater than in ASCII ordering
- Case-insensitive Comparison
Back to top
Input/Output Functions
- get-key - get a single key stroke from the keyboard
- read - read an expression
- print - print an expression on a new line
- prin1 - print an expression
- princ - print an expression without quoting
- pprint - pretty print an expression
- terpri - terminate the current print line
- flatsize - length of printed representation using prin1
- flatc - length of printed representation using princ
- format - do formated output
Back to top
File I/O Functions
- Character I/O
- Binary I/O
- bigendianp - is this a bigendian machine?
- open-binary - open a binary file stream
- Bytes
- Integer Numbers
- read-int - read a binary integer number from a stream
- write-int - write a binary integer number to a stream
- Floating Point Numbers
- read-float - read a binary floating point number from a stream
- write-float - write a binary floating point number to a stream
- Character and Bibary I/O
- close - close a file stream
- Operating System
Back to top
String Stream Functions
Back to top
System Functions
- load - load a source file
- save - save workspace to a file
- restore - restore workspace from a file
- dribble - create a file with a transcript of a session
- gc - force garbage collection
- expand - expand memory by adding segments
- alloc - change number of nodes to allocate in each segment
- info - show information about memory usage
- room - show memory allocation statistics
- type-of - returns the type of the expression
- peek - peek at a location in memory
- poke - poke a value into memory
- bigendianp - is this a big-endian machine?
- address-of - get the address of an xlisp node
- get-env - get the value of an environment variable
- system - execute a command of the operating system
- quit - exit XLISP
- exit - exit XLISP
- setup-console - set default console attributes
- echoenabled - turn console input echo on or off
Back to top
Nyquist / XLISP 2.0 -
Contents |
Tutorials |
Examples |
Reference