guile-user
[Top][All Lists]
Advanced

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

Re: How to select a module in C (guile 1.3.4)


From: Richard Guenther
Subject: Re: How to select a module in C (guile 1.3.4)
Date: Mon, 18 Jun 2001 10:18:49 +0200 (CEST)

On 16 Jun 2001, Marius Vollmer wrote:

> Richard Guenther <address@hidden> writes:
> 
> > I need to know how to switch the current module in C,
> 
> Preferably, you should try to avoid module system operations from C
> entirely.  Is it possible to write the `driver' that evaluates code in
> Scheme?

I managed to create a new module (and thereby making it active) by
gh_eval("(define-module (glame))"); But still I fail to somehow
"import" the scm module (I.e. call-with-current-continuation) -
I worked around that by doing

gh_eval("(set-current-module the-scm-module)
(define-module (glame-user))
(use-modules (glame))");

but thats a hack (or isnt it??).

Still I have the problem that the console interface to our program
(uses scm_shell()) differs from the GUI one (a text view widget and
a simple line edit, calls gh_eval_str() from the line edit "ENTER"
signal) - with scm_shell() the active module and the use-module
stuff gets overridden.

Richard.

--
Richard Guenther <address@hidden>
WWW: http://www.tat.physik.uni-tuebingen.de/~rguenth/
The GLAME Project: http://www.glame.de/




reply via email to

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