1 /* -----------------------------------------------------------------------------
3 * (c) The GHC Team 2009
5 * The C main() function for a standalone Haskell program.
7 * Note that this is not part of the RTS. It calls into the RTS to get things
8 * going. It is compiled to a separate Main.o which is linked into every
9 * standalone Haskell program that uses a Haskell Main.main function
10 * (as opposed to a mixed Haskell C program using a C main function).
12 * ---------------------------------------------------------------------------*/
14 #include "PosixSource.h"
18 /* Similarly, we can refer to the ZCMain_main_closure here */
19 extern StgClosure ZCMain_main_closure;
21 int main(int argc, char *argv[])
23 return hs_main(argc, argv, &ZCMain_main_closure);