more work on modules and hygiene, not finished yet, alas.
authorAndy Wingo <wingo@pobox.com>
Tue, 31 Mar 2009 05:06:35 +0000 (22:06 -0700)
committerAndy Wingo <wingo@pobox.com>
Fri, 17 Apr 2009 13:20:17 +0000 (15:20 +0200)
commit8e1d0d507ac3400fb57fce4196cc8cbc91977135
tree71226009aa5bcdcd2245dc1698059c5be1eeacbc
parentdaedb4920acdf6db31c375b4fdd142b002ddc77a
more work on modules and hygiene, not finished yet, alas.

* module/ice-9/compile-psyntax.scm: No more expansion-eval-closure.

* module/ice-9/expand-support.scm (strip-expansion-structures): Only @@
  names whose module is not the current module. Actually @@ serialization
  is disabled for this commit, just to get this one in and keep things
  working.

* module/ice-9/psyntax-pp.scm: Recompiled.

* module/ice-9/psyntax.scm (put-global-definition-hook)
  (get-global-definition-hook): Instead of going through that stupid
  getprop/putprop interface, let's just inline Guile-specific code here.
  (build-global-reference, build-global-assignment): Fix a bug where the
  module and public? were switched, which happily allowed things to
  compile. (We reintroduce a similar bug above in expand-support.)
  (lookup): Add a module argument.
  (global-extend): Adapt for put-global-definition-hook invocation.
  (syntax-type): Lookup with mod. Return mod even for lexicals and
  define-form -- why not.
  (chi-top, fluid-let-syntax, syntax, set!): Lookup with mod. Wrap with
  mod.

* module/ice-9/syncase.scm (expansion-eval-closure)
  (current-eval-closure, env->eval-closure): OK! So the idea is: module
  hygiene is syncase's business, not ours. So lose the eval-closure
  fluid. Also, eval closures are so 1990s.
  (sc-macro): But, we have to take the module from the env, sadly. In the
  future this will be different.
  Remove the rest of the eval-closure bits. Enable source reporting,
  while we're debugging.

* module/language/scheme/compile-ghil.scm (lookup-transformer): Adapt for
  eval closure fluid changes.
module/ice-9/compile-psyntax.scm
module/ice-9/expand-support.scm
module/ice-9/psyntax-pp.scm
module/ice-9/psyntax.scm
module/ice-9/syncase.scm
module/language/scheme/compile-ghil.scm