| 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. |
| - |
- |
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 |
As specified in the Exception word set. |
| ABORT" |
ABORT" |
As specified in the Exception word set. |
| ABS |
ABS |
Overloaded. Only for signed numbers. |
| ACCEPT |
ACCEPT |
|
| ALIGN |
ALIGN |
|
| ALIGNED |
ALIGNED |
|
| ALLOT |
ALLOT |
|
| AND |
AND |
|
| BASE |
BASE |
|
| BEGIN |
BEGIN |
|
| BL |
BL |
. |
| C! |
! |
|
| C, |
C, |
|
| C@ |
@ |
|
| CELL+ |
1+ |
For data type ADDRESS -> SINGLE. |
| CELLS |
CELLS |
|
| CHAR |
CHAR |
|
| CHAR+ |
1+ |
For data type CADDRESS. |
| CHARS |
CHARS |
|
| CONSTANT |
CONSTANT |
|
| COUNT |
|
Not implemented, because counted strings are not supported. |
| CR |
CR |
|
| CREATE |
CREATE |
|
| DECIMAL |
DECIMAL |
|
| DEPTH |
DEPTH |
Returns the number of basic data types on the data type heap. |
| DO |
DO |
Dynamically creates I as a local. |
| 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? |
Returns the address of the parameter 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 |
|
| FILL |
FILL |
Overloaded. |
| FIND |
SEARCH-ALL |
Requires name in address-count-notation.
Has two additional input parameters to specify additional search criteria.
Always returns a definition and a signed number. |
| FM/MOD |
FM/MOD |
|
| HERE |
HERE |
|
| 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 |
Overloaded for signed and unsigned numbers. |
| SIGN |
SIGN |
Expects a flag. |
| SM/REM |
SM/REM |
|
| SOURCE |
SOURCE |
|
| SPACE |
SPACE |
|
| SPACES |
SPACES |
|
| STATE |
STATE |
|
| SWAP |
SWAP |
Overloaded. |
| THEN |
THEN |
|
| TYPE |
TYPE |
Overloaded. |
| U. |
. |
|
| U< |
< |
|
| UM* |
M* |
|
| UM/MOD |
UM/MOD |
|
| UNLOOP |
UNLOOP |
|
| 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] |
|
| ] |
] |
|
| 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 a tuple as input parameter. |
| ROLL |
|
Not implemented. |
| SAVE-INPUT |
SAVE-INPUT |
Returns always one double-cell item. |
| 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 |
|
| VALUE |
VALUE |
Overloaded for single- and double-cell items. |
| WITHIN |
WITHIN |
Overloaded. |
| [COMPILE] |
[COMPILE] |
|
| \ |
\ |
Extended semantics. |
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.