diff options
author | Andy Wingo <wingo@pobox.com> | 2010-06-16 09:38:36 +0200 |
---|---|---|
committer | Andy Wingo <wingo@pobox.com> | 2010-06-16 09:38:36 +0200 |
commit | 393929957d9c2db998824e52c0a100b53ac64fe4 (patch) | |
tree | 38fefa071a5fc4b34ec3dce9eacae7d3fcf96964 | |
parent | 225dbf6fd496dbf09842fefaa500c2684eb119d9 (diff) | |
download | guile-393929957d9c2db998824e52c0a100b53ac64fe4.tar.gz |
load modules from within a known environment
* module/ice-9/boot-9.scm (try-module-autoload): Init the module
excursion with a fresh user module.
-rw-r--r-- | module/ice-9/boot-9.scm | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/module/ice-9/boot-9.scm b/module/ice-9/boot-9.scm index 8d0432354..450a6e4db 100644 --- a/module/ice-9/boot-9.scm +++ b/module/ice-9/boot-9.scm @@ -2598,6 +2598,9 @@ module '(ice-9 q) '(make-q q-length))}." (with-fluids ((current-reader #f)) (save-module-excursion (lambda () + ;; The initial environment when loading a module is a fresh + ;; user module. + (set-current-module (make-fresh-user-module)) (if version (load (find-versioned-module dir-hint name version %load-path)) |