INSPECT.LSP


INSPECT..LSP contains an XLISP editor/inspector. When the package feature is compiled in, the editor is in the TOOLS package.

Execute

(ins 'symbol) to edit a symbol.

(insf symbol) to edit the function binding of a symbol (allows changing the argument list or function type, lambda or macro).

The editor alters the current selection by copying so that aborting all changes is generally posible; the exception is when editing a closure, if the closure is backed out of, the change is permanent. Also, naturally, changing the values of structure elements, instance variables, or symbols cannot be undone.

For all commands taking a numeric argument, the first element of the selection is the 0th (as in NTH function).

Do not create new closures, because the environment will be incorrect. Closures become LAMBDA or MACRO expressions as the selection. Only the closure body may be changed; the argument list cannot be successfully modified, nor can the environment.

For class objects, the class variables, methods and message names can be modified. For instance objects, instance variables can be examined (if the object under-stands the message :<ivar> for the particular ivar), and changed (if :SET-IVAR is defined for that class, as it is if CLASSES.LSP is used). Structure elements can be examined and changed.

(command list on next page)

COMMANDS (all "hot keyed and case sensitive"):

?
List available commands
A
select the CAR of the current selection.
D
select the CDR of the current selection.
e n
select ("Edit") element n
r n x
Replaces element n with x.
X
eXit, saving all changes
Q
Quit, without saving changes
b
go Back one level (backs up A, D or e commands)
B n
go Back n levels.
l
List selection using pprint; if selection is symbol, give short description
v
Verbosity toggle
. n
change maximum print length (default 10)
# n
change maximum print depth (default 3)
! x
evaluates x and prints result, the symbol tools:@ is bound to the selection
R x
Replaces the selection with evaluated x, the symbol tools:@ is bound to the selection
ADDITIONAL COMMANDS (selection is a list or array):

( n m
inserts parenthesis starting with the nth element, for m elements.
) n
removes parenthesis surrounding nth element of selection, which may be array or list
[ n m
as in (, but makes elements into an array
i n x
Inserts x before nth element in selection.
d n
Deletes nth element in selection.
S x y
Substitute all occurances of y with x in selection (which must be a list). EQUAL is used for the comparison.

XLISP-PLUS - Version 2.1g - Tom Almy tom.almy@tek.com - 18 JUL 94
Generated with
WebMaker