This is the mail archive of the
kawa@sources.redhat.com
mailing list for the Kawa project.
Module-export and letrec
- To: kawa at sourceware dot cygnus dot com
- Subject: Module-export and letrec
- From: "Nic Ferrier" <nferrier at tapsellferrier dot co dot uk>
- Date: Wed, 14 Feb 2001 22:01:37 +0000
letrec is used in Kawa for tail-recursive procs (for understandable
reasons).
The only trouble is that you can't export a name proc from inside a
letrec. Because you can't do that you have to go to the trouble of
having an external definition that you assign to the letrec defined
proc that you want to export, like this:
(module-export someproc)
(define someproc #!null)
(letrec
((hiddenproc
(lambda (x)
(if (eqv? x 1)
1
(hiddenproc x-1)))))
(set! someproc hiddenproc))
This is inconvienant at best. Does anyone else think that Kawa should
allow exports from letrecs?
Nic