guile-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: set-current-module broken in current Guile CVS version


From: Dirk Herrmann
Subject: Re: set-current-module broken in current Guile CVS version
Date: Fri, 19 Jan 2001 18:12:09 +0100 (MET)

On 27 Dec 2000, Matthias Koeppe wrote (to bug-guile):

> Some of the Guile changes since 2000-12-13 broke
> `set-current-module'.
> 
> guile> (define-module (guile-ilisp))
> #<directory (guile-ilisp) 8082e70>
> guile> (define-module (guile-user))
> #<directory (guile-user) 8082a70>
> guile> (set-current-module (resolve-module '(guile-ilisp)))
> guile> (current-module)
> #<directory (guile-user) 8082a70> ; should be guile-ilisp

I can at least present you an intermediate solution that will allow you to
work interactively with modules.  If you want to switch to a different
module at the guile prompt, you can to the following:

guile> (begin (define-module (foo)) (scm-style-repl))

After that, foo will be the current module.  However, this way you have
actually started a repl within the repl.  If you are going to switch
modules repeatedly, you will use up more and more stack space.  To avoid
this, you can first (exit) from the inner repl to return to the outermost
one before you switch to another module and start a new repl.

I hope this helps,
Dirk Herrmann




reply via email to

[Prev in Thread] Current Thread [Next in Thread]