This is the mail archive of the
kawa@sources.redhat.com
mailing list for the Kawa project.
Re: multiple instances of modules
- To: Dennis <dennis at illusions dot com>
- Subject: Re: multiple instances of modules
- From: Per Bothner <per at bothner dot com>
- Date: 17 Jul 2001 00:03:21 -0700
- Cc: <kawa at sourceware dot cygnus dot com>
- References: <Pine.LNX.4.30.0107162251380.18162-100000@illusions.com>
Dennis <dennis@illusions.com> writes:
> Section 9.7 mentions "instance modules" that have a public default
> constructor. What would that look like? I know what that is in Java, but
> in Kawa, what does it look like?
Hm. In the latest version, I'm don't think you *can* specify
actions at constructor time. Instead, the actions in top-level
expressions are executed by run. For example:
(define a (make <foo>)) ;; For a compiled module foo.scm
(invoke a 'run)
This is useful in some circumstances,
but not perhaps when you just want to make a class. This is a
somewhat recent change, and I think I need to rethink it.
What I am getting convinced is that I shouldn't put off implementing
define-class much longer. I'll make this top priority.
> Must 'module-name' be used?
No - if you don't use module-name, a default name is picked depending
on compilation flags and the source file name.
--
--Per Bothner
per@bothner.com http://www.bothner.com/per/