* module/ice-9/psyntax.scm: Now that we have gone through the
intermediate step (in which both representations of syntax-object had
to coexist), change all callers to make-syntax-object to pass the third
argument, and restore the define-structure definition of syntax
objects.
* module/ice-9/psyntax-pp.scm: Recompile.
* module/ice-9/psyntax.scm (make-syntax-object): As an intermediate step
to adding modules to syntax objects, replace the definition of
syntax-object as a structure with an expanded-out definition that has
(1) a constructor that takes 2 or 3 arguments, and (2) a predicate that
works with vectors of length 3 or 4. I couldn't just redefine
make-syntax-object, for example, because these are internal
definitions, and we can't have duplicate bindings in a letrec.
* module/ice-9/Makefile.am: Replace annotate.scm with expand-support.scm.
* module/ice-9/annotate.scm: Removed; subsumed into expand-support.scm.
* module/ice-9/compile-psyntax.scm: Strip out expansion structures before
writing to disk.
* module/ice-9/expand-support.scm: New file. Provides annotation support,
and other compound data types for use by the expander. Currently the
only one that is used is the toplevel reference, <module-ref>, but we
will record lexicals this way soon.
* module/ice-9/psyntax-pp.scm: Regenerate.
* module/ice-9/psyntax.scm (build-global-reference)
(build-global-assignment): Instead of expanding out global references
as symbols, expand them as <module-ref> structures, with space to
record the module that they should be scoped against. This is in
anticipation of us actually threading the module info through the
syntax transformation, so that we can get hygiene with respect to
modules.
* module/ice-9/syncase.scm: Replace eval-when. Since sc-expand will give
us something that isn't Scheme because we put the <module-ref>
structures in it, strip that info whenever we actually do need scheme.
* module/language/scheme/compile-ghil.scm (lookup-transformer): Strip
expansion structures here too.
* module/language/scheme/expand.scm (language): Swap annotate for
expand-support. But this file will die soon, I think.
* module/ice-9/annotate.scm (set-annotation-stripped!): Fix prototype to
correspond to what syncase needs.
* module/ice-9/psyntax.scm (strip-annotation): Use `if', not `when', for
portability.
* module/ice-9/psyntax-pp.scm: Regenerate.
* module/ice-9/psyntax.scm (build-annotated): New helper, used by the
output constructors.
(build-application, build-conditional, build-lexical-reference)
(build-lexical-assignment, build-global-reference)
(build-global-assignment, build-global-definition, build-lambda)
(build-primref, build-data, build-sequence, build-let)
(build-named-let, build-letrec, build-lexical-var): Use
build-annotated, so we produce annotated source if we have source
information.
* module/ice-9/psyntax-pp.scm: Regenerated.
* module/ice-9/annotate.scm (<annotation>): Slightly more concise
printing.
(annotate): Don't create annotations if we have no source info.
* module/ice-9/psyntax.scm (annotation?): Remove this definition, as we
now provide annotation support.
* module/ice-9/psyntax-pp.scm: Regenerated.
* module/ice-9/syncase.scm: Use (ice-9 annotate).
* module/language/scheme/expand.scm (eval-when): Define the eval-when
transformer.
Moved ice-9/ and oop/ under module/, with the idea being that we have
only scheme under module/. Adjusted configure.in and Makefile.am
appropriately. Put oop/ at the end of the compilation order.