[gambit-list] Re: Meroon and Gambit

Eric Merritt cyberlync at gmail.com
Wed May 4 21:36:52 EDT 2005


> I copy the generated _meroon.o1 to the gambit install directory, in
> this case /pkgs/Gambit-C, link gsi++ to gsi, and gsc++ to gsc, in
> /pkgs/Gambit-C/bin, and put the following into
> /pkgs/Gambit-C/gambext.scm:
> 
> zuse-36% cat /pkgs/Gambit-C/gambcext.scm
> (case (string->symbol (car (##command-line)))
>    ((gsi++ gsc++) (load "/pkgs/Gambit-C/_meroon.o1"))
>    (else #f))
> (display "loading /pkgs/Gambit-C/gambcext.scm\n")
> 
> I can then start gsc with Meroon by gsc++ and gsi with Meroon by gsi++.

  That works for the Meroon system, but what about Meroon classes
defined by the user. Doesn't Meroon generate a few macros when classes
are defined? In this case you then have macro code mixed with
non-macro code. So if you 'load' it the macros aren't available
outside of the file. If you 'include' it the non-macro portion of the
code could be a duplicated if other code in your system also includes
that object definition.

  I guess this comes down to a bit of confusion on my part about
include/load semantics. Its my current understanding that macros
should always be specified in a file designed to be included.
Non-macro code should be in a file designed to be loaded. Most of the
time this isn't an issue, but sometimes you may not know when macros
are present and when they are not. A perfect example of this is the
meroon classes I described above.

  I am more then a bit confused by this so any clarification is
greatly appreciated.

Thanks,
Eric


More information about the Gambit-list mailing list