EMITand non-graphic characters:
unsigned char; in the future we might switch to
wchar_t(Comments on that requested).
TABLEs). The matching is performed using the C function
strncasecmp, whose function is probably influenced by the locale. E.g., the
Clocale does not know about accents and umlauts, so they are matched case-sensitively in that locale. For portability reasons it is best to write programs such that they work in the
Clocale. Then one can use libraries written by a Polish programmer (who might use words containing ISO Latin-2 encoded characters) and by a French programmer (ISO Latin-1) in the same program (of course,
WORDSwill produce funny results for some of the words (which ones, depends on the font you are using)). Also, the locale you prefer may not be available in other operating systems. Hopefully, Unicode will solve these problems one day.
WORDis called with the space character as a delimiter, all white-space characters (as identified by the C macro
isspace()) are delimiters.
PARSE, on the other hand, treats space like other delimiters.
PARSE-WORDtreats space like
WORD, but behaves like
(NAME), which is used by the outer interpreter (aka text interpreter) by default, treats all white-space characters as delimiters.
cs-item-size. At the time of this writing, an item consists of a (pointer to a) locals list (third), an address in the code (second), and a tag for identifying the item (TOS). The following tags are used:
[\]^_'are the digits with the decimal value 36-41. There is no way to input many of the larger digits.
-2 throwis performed.
s" /counted-string" environment? drop .. Currently 255 characters on all ports, but this may change.
/line. Currently 255 characters.
ENVIRONMENT?, in characters:
TYPEoutput to the file-id stored in the value
stdoutby default). Gforth uses unbuffered output when the user output device is a terminal, otherwise the output is buffered.
s" address-units-bits" environment? drop .. 8 in all current ports.
MAX-UD. The lower bounds for unsigned (and positive) types is 0. The lower bound for signed types on two's complement and one's complement machines machines can be computed by adding 1 to the upper bound.
PAD HERE - .. 104 characters on 32-bit machines. The buffer is shared with the pictured numeric output string. If overwriting
PADis acceptable, it is as large as the remaining dictionary space, although only as much can be sensibly used as fits in a counted string.
1 cells ..
1 chars .. 1 on all current ports.
lp@ tib - .. It is shared with the locals stack and TIBs of files that include the current file. You can change the amount of space for TIBs and locals stack at Gforth startup with the command line option
PAD HERE - .. 104 characters on 32-bit machines. The buffer is shared with
unused pad here - - ..
TABLEs). However, as explained above under character-set extensions, the matching for non-ASCII characters is determined by the locale you are using. In the default
Clocale all non-ASCII characters are matched case-sensitively.
okin interpret state,
compiledin compile state.
s" floored" environment? drop .. We leave the choice to
gcc(what to use for
/) and to you (whether to use
-55 throw(Floating-point unidentified fault), although a
-10 throw(divide by zero) would be more appropriate.
Go to the first, previous, next, last section, table of contents.