6.17.5 Recognizers

The recognizer concepts factor the central part of the text interpreter: The processing of one word after its name has been parsed.

The words and descriptions in this section are those that have found consensus in the standardization committee and will probably be standardized. There are also additional words implemented by Gforth and described in this section. Currently this manual does not tell which words are planned to be standardized and which are not. If you want to know that, see Recognizer committee proposal 2025-09-11.

Most programs just use the text interpreter as-is, and you can skip this chapter completely in this case, but if you are curious, see Default Recognizers. The next level of recognizer usage is to change which of the existing recognizers are used and in what order (see Recognizer order).

You may also want to define a new recognizer; a recognizer produces an on-stack representation of the recognized string, called a translation, which contains a translation token. You can use predefined translation tokens for defining your recognizer (see Defining recognizers), or first define a new tranlation token (see Defining translation tokens). Finally, you may want to process the translation (see Performing translation actions).