
16 Apr
2007
16 Apr
'07
1:39 p.m.
On 4/16/07, Isaac Dupree
The code generated by Alex is perfectly good Haskell98+cpp, except:
#if __GLASGOW_HASKELL__ >= 603 #include "ghcconfig.h" #else #include "config.h" #endif
If that "else" is modified to only trigger if we're using GHC at all[1], then plain C pre-processing[2] makes it run fine in Hugs, too.
[1] (which I don't know how to do, I actually just deleted the line #include "config.h" from the generated file)
Guarding the whole block with #ifdef __GLASGOW_HASKELL__ should do it. Cheers, Dinko