[Haskell-cafe] __GLASGOW_HASKELL__ macro in 7.2.1

JP Moresmau jpmoresmau at gmail.com
Fri Oct 14 16:47:45 CEST 2011


Hello list,
I must be doing something stupid, but what?

ghc --version
The Glorious Glasgow Haskell Compilation System, version 7.2.1

ghc -E -optP-dM -cpp Main.hs (per
http://www.haskell.org/ghc/docs/latest/html/users_guide/options-phases.html)

{-# LINE 1 "Main.hs" #-}
#define mingw32_HOST_OS 1
#define i386_BUILD_ARCH 1
#define __GLASGOW_HASKELL__ 702
#define __STDC_HOSTED__ 1
#define i386_HOST_ARCH 1
#define mingw32_BUILD_OS 1

I'm on Windows so everything else is correct except the line that
tells me I'm using 7.0.2.
Unfortunately I have code that works under 7.0.3 and breaks under
7.2.1 (and the 7.2.1 code breaks under 7.0.3, of course) so I don't
see anything other option than conditional compilation.

What am I doing wrong?

Thanks!

-- 
JP Moresmau
http://jpmoresmau.blogspot.com/



More information about the Haskell-Cafe mailing list