[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Guile-commits] GNU Guile branch, master, updated. release_1-9-13-71-gc9
From: |
Andy Wingo |
Subject: |
[Guile-commits] GNU Guile branch, master, updated. release_1-9-13-71-gc9b16ce |
Date: |
Thu, 18 Nov 2010 20:46:35 +0000 |
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU Guile".
http://git.savannah.gnu.org/cgit/guile.git/commit/?id=c9b16ceef7fe382aef3c4d236bdc83901d55d18d
The branch, master has been updated
via c9b16ceef7fe382aef3c4d236bdc83901d55d18d (commit)
from 3740c788ac67f7867ef41165380cff877666d219 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit c9b16ceef7fe382aef3c4d236bdc83901d55d18d
Author: Andy Wingo <address@hidden>
Date: Thu Nov 18 21:48:55 2010 +0100
add `reload-module' to boot-9
* module/ice-9/boot-9.scm (reload-module): New procedure,
programmatically reloads the source file corresponding to the given
module.
-----------------------------------------------------------------------
Summary of changes:
module/ice-9/boot-9.scm | 12 ++++++++++++
1 files changed, 12 insertions(+), 0 deletions(-)
diff --git a/module/ice-9/boot-9.scm b/module/ice-9/boot-9.scm
index b3b6893..24ce621 100644
--- a/module/ice-9/boot-9.scm
+++ b/module/ice-9/boot-9.scm
@@ -2252,6 +2252,18 @@ If there is no handler at all, Guile prints an error and
then exits."
(define (try-load-module name version)
(try-module-autoload name version))
+(define (reload-module m)
+ (let ((f (module-filename m)))
+ (if f
+ (save-module-excursion
+ (lambda ()
+ ;; Re-set the initial environment, as in try-module-autoload.
+ (set-current-module (make-fresh-user-module))
+ (primitive-load-path f)
+ m))
+ ;; Though we could guess, we *should* know it.
+ (error "unknown file name for module" m))))
+
(define (purify-module! module)
"Removes bindings in MODULE which are inherited from the (guile) module."
(let ((use-list (module-uses module)))
hooks/post-receive
--
GNU Guile
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Guile-commits] GNU Guile branch, master, updated. release_1-9-13-71-gc9b16ce,
Andy Wingo <=