main modules in GHC, deriving differences between GHC and Hugs

Graham Klyne gk@ninebynine.org
Fri, 13 Jun 2003 20:28:16 +0100


GHC seems to require a 'main' module in a file in order to generate an exe 
file.   This makes it awkward to create unit test programs, because I 
generally create one (to run stand-alone) for each major module.  Now I 
want to create a "master test" module that runs all the individual module 
tests.  But if the module tests are all "main" modules it seems I cannot 
bring them all together into a larger program.  Have I overlooked any way 
to create an executable program from any module containing a main function 
of the appropriate type?

There also seems to be a difference in the way that GHC and Hugs handle 
deriving clauses.  I haven't pinned this down, but I can try to provide 
more information if this is something the compiler developers not already 
aware of.

#g


-------------------
Graham Klyne
<GK@NineByNine.org>
PGP: 0FAA 69FF C083 000B A2E9  A131 01B9 1C7A DBCA CB5E