Maybe getting off-topic, but the language pragma TypeSynonymInstances could maybe have been of help there.<br><br>Cheers,<br>Dan<br><br><div class="gmail_quote">On Thu, Oct 11, 2012 at 3:11 PM, Guillaume Brunerie <span dir="ltr"><<a href="mailto:guillaume.brunerie@gmail.com" target="_blank">guillaume.brunerie@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hello,<br>
I have template-haskell-2.4.0.1 installed (I think that the latest<br>
version did not compile with ghc 6.12.3 so I installed the oldest<br>
supported version)<br>
<br>
Thanks, now I managed to compile Agda by removing the "qClassInstance"<br>
line, but I also had to change the line<br>
<br>
> instance Quasi U where<br>
<br>
with<br>
<br>
> instance Quasi (StateT (Map Type Dec, Map Type Bool) Q) where<br>
<br>
because I had an error saying that instance declarations cannot accept<br>
synonyms, or something like that.<br>
<br>
Thanks for your help,<br>
<br>
Guillaume<br>
<div class="HOEnZb"><div class="h5"><br>
<br>
On 2012/10/11 Nils Anders Danielsson <<a href="mailto:nad@chalmers.se">nad@chalmers.se</a>> wrote:<br>
> On 2012-10-10 22:21, Guillaume Brunerie wrote:<br>
>><br>
>> I’m trying to build Agda with ghc-6.12.3 (on the computers of the<br>
>> Institute for Advanced Study), but geniplate-0.6.0.2 fails to build.<br>
>> I’ve searched on Internet and it seems that this problem is known and<br>
>> that Nils Anders Danielsson has already sent a patch to make geniplate<br>
>> build with ghc-6.12.3 but this patch does not seem to have been<br>
>> applied upstream and I can’t find it anywhere.<br>
>><br>
>> Where can I find this patch?<br>
><br>
><br>
> In my local copy of Geniplate.hs the Quasi instance is defined as<br>
> follows:<br>
><br>
> instance Quasi U where<br>
> qNewName = lift . qNewName<br>
> qReport b = lift . qReport b<br>
> qRecover = error "Data.Generics.Geniplate: qRecover not implemented"<br>
> qReify = lift . qReify<br>
> #if MIN_VERSION_template_haskell(2,7,0)<br>
> qReifyInstances n = lift . qReifyInstances n<br>
> #elif MIN_VERSION_template_haskell(2,5,0)<br>
> qClassInstances n = lift . qClassInstances n<br>
> #endif<br>
> qLocation = lift qLocation<br>
> qRunIO = lift . qRunIO<br>
> #if MIN_VERSION_template_haskell(2,7,0)<br>
> qLookupName ns = lift . qLookupName ns<br>
> qAddDependentFile = lift . qAddDependentFile<br>
> #endif<br>
><br>
> Furthermore the LANGUAGE pragma has the following form:<br>
><br>
> {-# LANGUAGE TemplateHaskell, MultiParamTypeClasses, FlexibleInstances,<br>
> TypeSynonymInstances, PatternGuards, CPP #-}<br>
><br>
> This seems to make Geniplate work on GHC 6.12.3, 7.0.4, 7.4.2 and 7.6.1.<br>
><br>
> --<br>
> /NAD<br>
><br>
_______________________________________________<br>
Agda mailing list<br>
<a href="mailto:Agda@lists.chalmers.se">Agda@lists.chalmers.se</a><br>
<a href="https://lists.chalmers.se/mailman/listinfo/agda" target="_blank">https://lists.chalmers.se/mailman/listinfo/agda</a><br>
<br>
<br>
</div></div></blockquote></div><br>