Gforth (since 1.0) also recognizes the following literals:
You can input an execution token (xt) of a word by prefixing the name
of the word with the backquote `
(e.g., `dup
). An
advantage over using '
or [']
is you do not need to
switch between them when copying and pasting code from inside to
outside a colon definition or vice versa. A disadvantage is that this
syntax is non-standard.
You can input a name token (nt) of a word by prefixing the name of the
word with ``
(e.g., ``dup
). This syntax is also
non-standard.
You can input a body address of a word by surrounding it with <
and >
(e.g., <spaces>
). You can also input an address
that is at a positive offset from the body address (typically an
address in that body), by putting +
and a number (see syntax
above) between the word name and the closing >
(e.g.,
<spaces+$15>
, <spaces+-3>
). You will get the body address
plus the number. This feature exists to allow copying
and pasting the output of ...
(see Examining data).
In addition, by default Gforth recognizes words with rec-nt
and
rec-scope
, and stores in or adds to value-flavoured words with
rec-to
, but these do not recognize literals, so they are
discussed elsewhere (see Default Recognizers).