[Agda] Building Agda with ghc-6.12.3: build failure on geniplate
Guillaume Brunerie
guillaume.brunerie at gmail.com
Thu Oct 11 15:11:32 CEST 2012
Hello,
I have template-haskell-2.4.0.1 installed (I think that the latest
version did not compile with ghc 6.12.3 so I installed the oldest
supported version)
Thanks, now I managed to compile Agda by removing the "qClassInstance"
line, but I also had to change the line
> instance Quasi U where
with
> instance Quasi (StateT (Map Type Dec, Map Type Bool) Q) where
because I had an error saying that instance declarations cannot accept
synonyms, or something like that.
Thanks for your help,
Guillaume
On 2012/10/11 Nils Anders Danielsson <nad at chalmers.se> wrote:
> On 2012-10-10 22:21, Guillaume Brunerie wrote:
>>
>> I’m trying to build Agda with ghc-6.12.3 (on the computers of the
>> Institute for Advanced Study), but geniplate-0.6.0.2 fails to build.
>> I’ve searched on Internet and it seems that this problem is known and
>> that Nils Anders Danielsson has already sent a patch to make geniplate
>> build with ghc-6.12.3 but this patch does not seem to have been
>> applied upstream and I can’t find it anywhere.
>>
>> Where can I find this patch?
>
>
> In my local copy of Geniplate.hs the Quasi instance is defined as
> follows:
>
> instance Quasi U where
> qNewName = lift . qNewName
> qReport b = lift . qReport b
> qRecover = error "Data.Generics.Geniplate: qRecover not implemented"
> qReify = lift . qReify
> #if MIN_VERSION_template_haskell(2,7,0)
> qReifyInstances n = lift . qReifyInstances n
> #elif MIN_VERSION_template_haskell(2,5,0)
> qClassInstances n = lift . qClassInstances n
> #endif
> qLocation = lift qLocation
> qRunIO = lift . qRunIO
> #if MIN_VERSION_template_haskell(2,7,0)
> qLookupName ns = lift . qLookupName ns
> qAddDependentFile = lift . qAddDependentFile
> #endif
>
> Furthermore the LANGUAGE pragma has the following form:
>
> {-# LANGUAGE TemplateHaskell, MultiParamTypeClasses, FlexibleInstances,
> TypeSynonymInstances, PatternGuards, CPP #-}
>
> This seems to make Geniplate work on GHC 6.12.3, 7.0.4, 7.4.2 and 7.6.1.
>
> --
> /NAD
>
More information about the Agda
mailing list