This is the mail archive of the kawa@sourceware.org mailing list for the Kawa project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: the right way to compile and load modules


On 05/12/2014 09:09 PM, mikel evins wrote:
Okay, so I add a module-export form to bar.scm and recompile.
Now foo.class runs as expected, but there's a new problem: if I load bar.scm, kawa complains that bar is exported but never defined.

A possible problem is that load is line-by-line, which is fundamentally
incompatible with modules as a unit - and thus with export.  If you use
load, leave off the exports.

Better to always use require (or r7rs import).  You can use require to
import a source file (though you can't yet use import for that).
I don't have an example - it late, I'm tired, and my initial experiment
is doing something weird. :-(

More tomorrow.
--
	--Per Bothner
per@bothner.com   http://per.bothner.com/


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]