
	This is a list of all the FORTH words implemented. In the case where
there are two functions, one for integer, one for floating, they will be
listed together; the floating version will start with "f".

	A "word" refers to a VAX 32-bit longword; a "float" refers
to an 32-bit F-format VAX floating word. The term "opstack" or
"operand stack" will refer to the regular FORTH stack; "return stack"
is the "other" stack, and is implemented with the VAX's SP register.

over ( x y -- x y x )
	Copy second to top

abs, fabs ( x -- |x| )
	Change sign of top of stack if it's negative

max, fmax ( x y -- max(x,y) )
	Take the greater of the top two elements

min, fmin (x y -- min(x,y) )
	Take the lesser of the top two elements

c@ ( d a -- )
	Store the byte quantity "d" at byte address "a".

c! ( a -- d)
	Fetch the byte quantity "d" from byte address "a".

negate, fnegate ( x -- -x )
	Replace top of stack with its negation.

here ( -- a )
	Push the address of the next open memory location in the
dictionary to stack.

>r ( -- d )
	Move one word from the return stack to the operand stack.

r> ( d -- )
	Move one word from the operand stack to return stack.

fill ( a n d -- )
	Fill "n" bytes of memory starting at "a" with the value "d".

pick ( d -- x )
	Get the "d"th word on the opstack (zero-based, starting from the
word below "d") to the top of stack.

, ( d -- )
	Move the word "d" into the next open dictionary word, advancing
HERE.

c, ( d -- )
	As ",", but only a byte operation is done.

rot ( x y z -- y z x )
	Move the third element to the top.

-rot ( y z x -- x y z )
	Move the top element to the third.

allot ( d -- )
	Add "d" to HERE, effectively moving the bottom of the dictionary
forward "d" bytes.

2dup ( x y -- x y x y )
	Duplicate the top two words.

2swap ( w x y z -- y z w x )
	Swap the top two words with the second-to-the-top two words.

(
	Start a comment which is ended by a ")" or newline.

abort
	Initialize forth, start interpreting from the keyboard again.

halt
	Exit back to UNIX.

outpop
	Close the current output file & start using the previous output
file. This is a no-op if this is the first output file.

output
	Take the next word in the input stream & try to open it for writing.
If you can't, call "abort". Otherwise, make it the current output file,
pushing the current output onto a stack so that a later "outpop" will
close this file & continue with the old one.

input
	As output, but open for reading. There is no corresponding "inpop",
as EOF status will cause the equivalent action.

true, false ( -- b )
	Push the boolean true and false values onto the stack. These
values are used uniformly by all of Vforth.

or, and
	Bitwise OR and AND operations. These will work with "true"
and "false" to provide logical functionality.

=, f= ( x y -- b )
	Return whether x is equal to y.

>, f> ( x y -- b )
	Return whether x is greater than y.

<, f< ( x y -- b )
	Return whether x is less than y.

drop ( x -- )
	Drop the top of stack.

2drop ( x y -- )
	Drop the top two items from the stack.

swap ( x y -- y x )
	Exchange the top two items.

dup ( x -- x x )
	Duplicate the top item.

if ... [ else ] ... endif
	The conditional structure. Note "endif", not "then".

begin ... again
	Unconditional looping structure.

begin ... until
	Conditional looping--will loop until the "until" receives a
boolean "true" on the stack.

begin ... while ... repeat
	Looping structure where the test is at the "while" word.

do ... loop
	Counting loop.

do ... +loop
	As do...loop, but +loop takes the amount to increment by.

leave
	Causes the innermost loop to reach its exit condition. The
next execution of "loop" or "+loop" will fall through.

i,j,k
	The loop indices of (respectively) the innermost, second, and
third loops.

@ ( a -- x )
	Fetch a word at address "a".

! ( x a -- )
	Store a word at address "a".

variable
	Take the next word and add it to the dictionary as a variable.
Subsequent references to this name will return an address which is the
word allocated to this variable. Uses such as
variable foobar 400 allot
	will make "foobar" return the address of a 404-byte array (the
initially allocated longword, 4 bytes, plus the allot'ed 400 bytes).

constant
	Like variable, but later references to this word return the
numerical constant. Thus
42 constant ascii_star
ascii_star emit
	will print a star to the current output device.

:
	Start compilation mode for the next word in the stream.

;
	End compilation mode, unsmudge the entry.

mod ( x y -- r )
	Return the remainder of x/y. This is explicitly calculated
as x-int(x/y)*x.

/,f/ ( x y -- d )
	Return the result of x/y. Dividing by zero is undefined.

*,f*,-,f-,+,f+ ( x y -- d )
	Return the result of the applied binary operation to the
two arguments.

i->f ( i -- f )
	Convert the integer "i" to the equivalent floating format
"f".

f->i ( f -- i )
	Convert the floating number "f" to the equivalent integer "i".
Integer portions of "f" will be truncated; for details, refer to the
"cvtfl" instruction in the VAX architecture handbook.

emit ( c -- )
	Print the specified character to the current output unit.

cr
	Print a newline sequence to the current output unit.

f. ( f -- )
	Print the floating-point number.

."
	Print the string immediately (in interpretive mode) or compile
code which will print the string (in compilation mode).

(.")
	Run-time support word for .".

. ( i -- )
	Print the integer.

sintab
	An array of sin() values.

sin ( i -- s )
	"i" is a degree measure; "s" is sin(i)*10000.

fsin ( f -- s )
	"f" is the degree measure; "s" is the sin() value.

cos, fcos
	As sin, fsin, but for cos() values.

decimal
	Set Vforth's current base to 10.

hex
	Set Vforth's current base to hexadecimal (16).

base
	A Vforth variable which holds the current base.

state
	A variable which holds the current state; 0 = interpreting,
non-0 means compiling.

