Hello,
Can someone kindly look at this small example and tell me what's wrong? I get
this
david@rascar:~ 8 $ guile
GNU Guile 2.0.0.160-39be
...
scheme@(guile-user)> (use-modules (mg-3))
(letstry)
mg-3.scm:17:2: In procedure letstry:
mg-3.scm:17:2: In procedure module-lookup: Unbound variable: dialog
Entering a new prompt. Type `,bt' for a backtrace or `,q' to continue.
Many thanks,
David
ps: sometimes guile does not 'comeback from an error' with a prompt
invitation, like in my case here above: the guile-prompt only come back
after I enter something, like ,q in this case.
(define-module (mg-1)
:use-module (oop goops)
:duplicates (merge-generics)
:export (<widget-a>
dialog
))
(define-class <widget-a> ()
(dialog :accessor dialog :init-keyword :dialog :init-value 'dialog-a)
)
(define-module (mg-2)
:use-module (oop goops)
:duplicates (merge-generics)
:export (<widget-b>
dialog
))
(define-class <widget-b> ()
(dialog :accessor dialog :init-keyword :dialog :init-value 'dialog-b)
)
(define-module (mg-3)
:use-module (oop goops)
:use-module (mg-1)
:use-module (mg-2)
:duplicates (merge-generics)
:export (a
b
letstry))
(define a (make <widget-a>))
(define b (make <widget-b>))
(define (letstry)
(dialog a)
(dialog b))
#!
(use-modules (macros push))
(push! "/usr/local/share/guile/alto/2.0/tests"
%load-path)
(use-modules (mg-3))
(letstry)
!#