[plt-dev] Rationale for kernel-form-identifier-list
The kernel-form-identifier-list function from syntax/kerncase is
useful for head expansion and similar low-level macro hackery, but its
specifications is somewhat quirky. It leaves out (module-)top-level
forms (module, #%plain-module-begin, #%require, and #%provide), and
includes the non-fully-expanded form letrec-syntaxes+values. Is there
a compelling reason for this? Local (usually head-)expansion in
internal definition contexts doesn't need the extra bindings, but I
don't see that it would hurt to include them. However, local
expansion in a module context does need the extra bindings, so it
would help to add them (and I don't see that we need a separate
binding for it).
As for letrec-syntaxes+values, if it gets expanded away, I don't see
why it's in the list at all. If it doesn't, it should be included in
the "Fully Expanded Programs" grammar.
Carl Eastlund