ANS Forth - StrongForth Cross Reference

Core Word Set

ANS Forth strongForth Remarks
! ! Overloaded.
# #  
#> #>  
#S #S  
' ' Returns a definition instead of an execution token.
( \ Extended semantics. Use ( for stack diagrams only.
* * Overloaded.
*/ */ Overloaded.
*/MOD */MOD Overloaded.
+ + Overloaded. Performs address arithmetic.
+! +! Overloaded. Performs address arithmetic.
+LOOP +LOOP Overloaded. Performs address arithmetic.
, , Overloaded for SINGLE and DOUBLE. Can be applied to all memory spaces.
- - Overloaded. Performs address arithmetic.
. . Overloaded.
." ." State-smart.
/ / Overloaded.
/MOD /MOD Overloaded.
0< 0< Overloaded.
0= 0= Overloaded.
1+ 1+ Overloaded. Performs address arithmetic.
1- 1- Overloaded. Performs address arithmetic.
2! ! Can only be applied to double-cell items, but not to pairs of single-cell items.
2* 2* Overloaded. Can only be applied to numbers.
LSHIFT Overloaded. Can only be applied to logical values.
2/ 2/ Overloaded. Can only be applied to numbers.
RSHIFT Overloaded. Can only be applied to logical values.
2@ @ Can only be applied to double-cell items, but not to pairs of single-cell items.
2DROP DROP Can only be applied to double-cell items, but not to pairs of single-cell items.
2DUP DUP Can only be applied to double-cell items, but not to pairs of single-cell items.
2OVER OVER Can only be applied to double-cell items, but not to pairs of single-cell items.
2SWAP SWAP Can only be applied to double-cell items, but not to pairs of single-cell items.
: :  
; ;  
< < Overloaded.
<# <#  
= = Overloaded.
> > Overloaded.
>BODY >BODY Applied to a definition instead of an execution token.
>IN >IN  
>NUMBER >NUMBER  
>R >R Creates and initializes a local R@.
?DUP   Not implemented.
@ @ Overloaded.
ABORT ABORT  
ABORT" ABORT"  
ABS ABS Overloaded. Only for signed numbers.
ACCEPT ACCEPT  
ALIGN ALIGN Can be applied to all memory spaces.
ALIGNED ALIGNED  
ALLOT ALLOT Can be applied to all memory spaces.
AND AND  
BASE BASE  
BEGIN BEGIN  
BL BL Hidden by the assembler version of BL.
C! !  
C, C,  
C@ @  
CELL+ 1+  
CELLS CELLS  
CHAR CHAR  
CHAR+ 1+  
CHARS CHARS  
CONSTANT CONSTANT  
COUNT   Not implemented, because counted strings are not supported.
CR CR  
CREATE CREATE Does not supply a word with a default runtime semantics.
DECIMAL DECIMAL  
DEPTH DEPTH Returns the number of basic data types on the data type heap.
DO DO  
DOES> DOES> Must be followed by a stack diagram.
DROP DROP Overloaded.
DUP DUP Overloaded.
ELSE ELSE  
EMIT EMIT  
. Only for data type CHARACTER.
ENVIRONMENT? ENVIRONMENT? Always returns a double number and a flag.
EVALUATE EVALUATE  
EXECUTE EXECUTE Individually created by )PROCREATES. Each version can only be applied to one specific subtype of TOKEN.
EXIT EXIT Does not require UNLOOP when used inside DO loops.
FILL FILL Overloaded.
FIND FIND Requires name in address-count-notation. Has two additional input parameters to specify the search rule. Always returns a definition and a signed number.
FM/MOD FM/MOD  
HERE HERE Can be applied to all memory spaces.
HOLD HOLD  
I I A local dynamically generated by DO and ?DO, and removed by LOOP and +LOOP.
IF IF  
IMMEDIATE IMMEDIATE  
INVERT INVERT  
J J A local dynamically generated by DO and ?DO, and removed by LOOP and +LOOP.
KEY KEY  
LEAVE LEAVE  
LITERAL LITERAL Overloaded.
LOOP LOOP Overloaded. Performs address arithmetic.
LSHIFT LSHIFT Overloaded with an additional version for single bit shift.
M* M* Overloaded.
MAX MAX Overloaded.
MIN MIN Overloaded.
MOD MOD Overloaded.
MOVE MOVE Overloaded.
NEGATE NEGATE Overloaded.
OR OR  
OVER OVER Overloaded.
POSTPONE POSTPONE  
QUIT QUIT  
R> R> Removes local R@.
R@ R@ A local dynamically generated by >R and removed by R>.
RECURSE RECURSE  
REPEAT REPEAT  
ROT ROT Overloaded.
RSHIFT RSHIFT Overloaded with an additional version for single bit shift.
S" " Name changed because counted strings are not supported.
S>D S>D  
SIGN SIGN Expects a flag.
SM/REM SM/REM  
SOURCE SOURCE  
SPACE SPACE  
SPACES SPACES Overloaded versions for signed and unsigned numbers.
STATE STATE  
SWAP SWAP Overloaded.
THEN THEN  
TYPE TYPE Overloaded.
U. .  
U< <  
UM* M*  
UM/MOD UM/MOD  
UNLOOP   Not implemented, because the loop parameters are locals.
UNTIL UNTIL  
VARIABLE VARIABLE Requires an initialization value.
WHILE WHILE  
WORD PARSE Different semantics as specified in ANS Forth A.6.2.2008. WORD is not implemented because counted strings are not supported.
PARSE-WORD
XOR XOR  
[ [  
['] [']  
[CHAR] [CHAR]  
] ]  

Core Extension Word Set

ANS Forth strongForth Remarks
#TIB #TIB  
.( .(  
.R .R Overloaded.
0<> 0<> Overloaded.
0> 0> Overloaded.
2>R >R Creates and initializes a local R@. Can only be applied to double-cell items, but not to pairs of single-cell items.
2R> R> Removes local R@. Can only be applied to double-cell items, but not to pairs of single-cell items.
2R@ R@ A local dynamically generated by >R and removed by R>. Can only be applied to double-cell items, but not to pairs of single-cell items.
:NONAME :NONAME Returns a definition instead of an execution token.
<> <> Overloaded.
?DO ?DO  
AGAIN AGAIN  
C"   Not implemented, because counted strings are not supported.
CASE CASE  
COMPILE, COMPILE, Applied to a definition instead of an execution token.
CONVERT   Not implemented.
ENDCASE ENDCASE  
ENDOF ENDOF  
ERASE ERASE Overloaded.
EXPECT   Not implemented. May be replaced by ACCEPT.
FALSE FALSE  
HEX HEX  
MARKER MARKER  
NIP NIP Overloaded.
OF OF  
PAD PAD  
PARSE PARSE  
PICK   Not implemented.
QUERY   Not implemented.
REFILL REFILL  
RESTORE-INPUT RESTORE-INPUT Requires always one double number as input parameter.
ROLL   Not implemented.
SAVE-INPUT SAVE-INPUT Returns always one double number.
SOURCE-ID SOURCE-ID Implemented as a VALUE.
SPAN   Not implemented.
TIB TIB  
TO TO  
TRUE TRUE  
TUCK TUCK Overloaded.
U.R .R  
U> >  
UNUSED UNUSED Can be applied to all memory spaces.
VALUE VALUE  
WITHIN WITHIN Overloaded.
[COMPILE] [COMPILE]  
\ \ Extended semantics.

Block Word Set

ANS Forth strongForth Remarks
BLK BLK  
BLOCK BLOCK  
BUFFER BUFFER  
EVALUATE EVALUATE  
FLUSH FLUSH  
LOAD LOAD  
SAVE-BUFFERS SAVE-BUFFERS  
UPDATE UPDATE  

Block Extension Word Set

ANS Forth strongForth Remarks
EMPTY-BUFFERS EMPTY-BUFFERS  
LIST LIST  
REFILL REFILL  
SCR SCR  
THRU THRU  
\ \ Extended semantics.

Double-Number Word Set

ANS Forth strongForth Remarks
2CONSTANT CONSTANT Can only be applied to double-cell items, but not to pairs of single-cell items.
2LITERAL LITERAL Can only be applied to double-cell items, but not to pairs of single-cell items.
2VARIABLE VARIABLE Can only be applied to double-cell items, but not to pairs of single-cell items. Requires an initialization value.
D+ +  
D- -  
D. .  
D.R .R  
D0< 0<  
D0= 0=  
D2* 2* Can only be applied to numbers.
D2/ 2/ Can only be applied to numbers.
D< <  
D= =  
D>S D>S  
DABS ABS Only for signed numbers.
DMAX MAX  
DMIN MIN  
DNEGATE NEGATE  
M*/ */ All numbers are unsigned.
M+ +  

Double-Number Extension Word Set

ANS Forth strongForth Remarks
2ROT ROT Can only be applied to double-cell items, but not to pairs of single-cell items.
DU< <  

Exception Word Set

ANS Forth strongForth Remarks
CATCH CATCH Does not produce a different stack effect if an exception is thrown.
THROW THROW  

Exception Extension Word Set

ANS Forth strongForth Remarks
ABORT ABORT  
ABORT" ABORT"  

Locals Word Set

ANS Forth strongForth Remarks
(LOCAL) (LOCAL)  
TO TO  

Locals Extension Word Set

ANS Forth strongForth Remarks
LOCALS| LOCALS|  

Programming-Tools Word Set

ANS Forth strongForth Remarks
.S .S Displays data types instead of stack values.
? ?  
DUMP DUMP Overloaded.
SEE SEE  
WORDS WORDS Extended functionality.

Programming-Tools Extension Word Set

ANS Forth strongForth Remarks
;CODE ;CODE  
AHEAD AHEAD  
ASSEMBLER ASSEMBLER Dummy word.
BYE BYE  
CODE CODE  
CS-PICK   Not implemented.
CS-ROLL   Not implemented.
EDITOR EDITOR Dummy word.
FORGET   Not implemented.
STATE STATE  
[ELSE] [ELSE]  
[IF] [IF]  
[THEN] [THEN]  

String Word Set

ANS Forth strongForth Remarks
-TRAILING -TRAILING  
/STRING /STRING Overloaded with an additional version for one single character.
BLANK BLANK  
CMOVE MOVE Overloaded. Can only be used for a move, but not for memory propagation.
CMOVE> MOVE Overloaded. Can only be used for a move, but not for memory propagation.
COMPARE COMPARE Overloaded.
SEARCH SEARCH  
SLITERAL SLITERAL  

Note: Many words have specific data type restrictions regarding their input parameters. For example, + can not be used to add an address to an integer, but an integer can be added to an address, giving an address.


Dr. Stephan Becher - December 29th, 2005