Skip to content

Commit 1831a38

Browse files
authored
[spec] Allow explicit keyword definitions (#1553)
Rather than describing keyword tokens as always being defined implicitly by terminal symbols in syntactic productions, describe them as being defined implicitly or explicitly. This accounts for the explicit definitions of `offset` and `align` phrases, which are lexically keywords, later in the chapter. Fixes #1552.
1 parent 9789e17 commit 1831a38

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

document/core/text/lexical.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ That is, the next token always consists of the longest possible sequence of char
5858
Tokens can be separated by :ref:`white space <text-space>`,
5959
but except for strings, they cannot themselves contain whitespace.
6060

61-
The set of *keyword* tokens is defined implicitly, by all occurrences of a :ref:`terminal symbol <text-grammar>` in literal form, such as :math:`\text{keyword}`, in a :ref:`syntactic <text-syntactic>` production of this chapter.
61+
*Keyword* tokens are defined either implicitly by an occurrence of a :ref:`terminal symbol <text-grammar>` in literal form, such as :math:`\text{keyword}`, in a :ref:`syntactic <text-syntactic>` production of this chapter, or explicitly where they arise in this chapter.
6262

6363
Any token that does not fall into any of the other categories is considered *reserved*, and cannot occur in source text.
6464

0 commit comments

Comments
 (0)