[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
RE: [plt-scheme] Modular Include
The easiest way is to convert the code into a MzScheme `module' and use
the `require' form.
Example:
file1.ss
(module file1 mzscheme
(provide foo)
(define foo ...))
file2.ss
(module file2 mzscheme
(require "file1.ss")
(foo ...))
-- Paul
> -----Original Message-----
> From: owner-plt-scheme@fast.cs.utah.edu [mailto:owner-plt-
> scheme@fast.cs.utah.edu] On Behalf Of Paulo J. Matos
> Sent: Tuesday, May 14, 2002 4:36 PM
> To: plt-scheme@fast.cs.utah.edu
> Subject: [plt-scheme] Modular Include
>
> Hi all,
>
> What's the best way to use the code in another file? I could do
> (load "file.scm") but is there a more modular (better in the
> programming sense) way than this?
>
> Best regards,
>
> --
> Paulo J. Matos : pocm(_at_)rnl.ist.utl.pt
> Instituto Superior Tecnico - Lisbon
> Software & Computer Engineering - A.I.
> - > http://www.rnl.ist.utl.pt/~pocm
> ---
> Yes, God had a deadline...
> So, He wrote it all in Lisp!