The valid patterns for tokens are summarized in the next figure.
|
Figure 2.17: Valid patterns for tokens
Note that nnnnn has number syntax, neither xxxxx nor ppppp has number syntax, and aaaaa has any syntax.
A summary of rules concerning package markers follows. In each case, examples are offered to illustrate the case; for presentational simplicity, the examples assume that the readtable case of the current readtable is :upcase.
KEYWORD
package.
It also sets the symbol-value
of the newly-created symbol to that
same symbol so that the symbol will self-evaluate.
For example,
:bar
, when read, interns BAR
as an external symbol in the KEYWORD
package.
For example,
foo:bar
, when read, looks up BAR
among the external symbols of
the package named FOO
.
For example,
foo::bar
, when read, interns BAR
in the package named FOO
.
For example,
bar
, when read, interns BAR
in the current package.
For example,
assuming the readtable case of the current readtable is :upcase,
editor:buffer
refers to the external symbol
named BUFFER
present in the package named editor
,
regardless of whether there is a symbol named BUFFER
in
the current package. If there is no package named
editor
, or if no symbol named BUFFER
is present in editor
, or if BUFFER
is not exported by
editor
, the reader signals
a correctable error.
If editor::buffer
is seen, the effect is exactly the same as
reading buffer
with the EDITOR
package being the current package.