ghc panic on TH and deriveJSON
{-# LANGUAGE CPP,TemplateHaskell #-}
module Main (main) where
import Data.Aeson.TH
data Test = Test Int deriving Show
deriveJSON id ''Test
main = return ()
will give
Building aeson-test-0.0.1...
Preprocessing test suite 'test-aeson-test' for aeson-test-0.0.1...
[1 of 1] Compiling Main ( src\Main.hs, dist\build\test-aeson-test\test-aeson-test-tmp\Main.o )
Loading package ghc-prim ... linking ... done.
Loading package integer-gmp ... linking ... done.
Loading package base ... linking ... done.
Loading package array-0.4.0.0 ... linking ... done.
Loading package bytestring-0.9.2.1 ... linking ... done.
Loading package deepseq-1.3.0.0 ... linking ... done.
Loading package containers-0.4.2.1 ... linking ... done.
ghc.exe: panic! (the 'impossible' happened)
Loading package text-0.11.2.3 ... linking ... done.
(GHC version 7.4.2 for i386-unknown-mingw32):
Loading package attoparsec-0.10.4.0 ... linking ... done.
loadObj "C:\\Users\\User\\AppData\\Roaming\\cabal\\hashable-1.2.0.5\\ghc-7.4.2\\HShashable-1.2.0.5.o": failed
Loading package blaze-builder-0.3.1.0 ... linking ... done.
Loading package dlist-0.5 ... linking ... done.
Please report this as a GHC bug: http://www.haskell.org/ghc/reportabug
Loading package hashable-1.2.0.5 ...
ghc.exe: Unknown PEi386 section name `.text.startup' (while processing: C:\Users\User\AppData\Roaming\cabal\hashable-1.2.0.5\ghc-7.4.2\HShashable-1.2.0.5.o)