[plt-scheme] The usefullness of module systems

From: Corey Sweeney (corey.sweeney at gmail.com)
Date: Fri Oct 8 15:52:07 EDT 2004

Hi.  I currenly use closures instead of modules, and am looking at
switching to modules.  So far I see the advantages as the "stackable
macros" thing (of which i currenly have no macros to stack).  The big
downside that i see, is that it will make development much harder,
because when i go to probe a variable inside the module i'm
developing, it'll just say "undefined identifier".  I've tried doing

(define x 7)
(provide mod-env)
(define mod-env (interaction-environment))

inside the module, then doing 

(eval `x mod-env)

at top level, and i still get "undefined identifier".  Is there any
good way to get a prompt with access to the internal vars?

My other options that I see are:
Write it outside the module, and then wrap it in the module after your
your sure you'll never make any more changes. (i.e. never :)
Attempt using my "define-global" (call/cc trick) to mask define inside
the module, dumping all internal vars into the global environment.

,  without useing my "define-global" which

Posted on the users mailing list.