Define-syntax, let-syntax, and letrec-syntax are
analogous to define, let, and letrec, but they bind
syntactic keywords to macro transformers instead of binding variables
to locations that contain values. Furthermore, there is no
define-syntax analogue of the internal definitions described in
section .
These new expression types and the pattern language described in
section are added to Scheme by augmenting the
BNF in section
with the following new productions. Note
that the identifier ... used in some of these productions is not
a metasymbol.
Although macros may expand into definitions in any context that permits definitions, it is an error for a definition to shadow a syntactic keyword whose meaning is needed to determine whether some definition in the group of top-level or internal definitions that contains the shadowing definition is in fact a definition, or is needed to determine the boundary between the group and the expressions that follow the group. For example, the following are errors: