<div dir="ltr">what GHC version and cabal install version please?<div><br></div><div>could you hop on IRC? i fear that your attempts at solving things are creating more confusion than resolution, and it might be easier to address those in real time, because theres a lot of missing information here!</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Dec 23, 2014 at 11:15 AM, Dominic Steinitz <span dir="ltr"><<a href="mailto:dominic@steinitz.org" target="_blank">dominic@steinitz.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">I am on a Mac as you have cleverly deduced. I tried cabal install --with-gcc=gcc-4.9 but no luck.<br>
<span class="im HOEnZb"><br>
Dominic Steinitz<br>
<a href="mailto:dominic@steinitz.org">dominic@steinitz.org</a><br>
<a href="http://idontgetoutmuch.wordpress.com" target="_blank">http://idontgetoutmuch.wordpress.com</a><br>
<br>
</span><div class="HOEnZb"><div class="h5">On 23 Dec 2014, at 16:13, Erik Hesselink <<a href="mailto:hesselink@gmail.com">hesselink@gmail.com</a>> wrote:<br>
<br>
> Are you on a Mac? OS X switched to clang, which caused all kinds of<br>
> problems as GHC uses the C compiler as a C preprocessor, and clang<br>
> behaves differently from gcc.<br>
><br>
> Erik<br>
><br>
> On Tue, Dec 23, 2014 at 4:06 PM, Dominic Steinitz <<a href="mailto:dominic@steinitz.org">dominic@steinitz.org</a>> wrote:<br>
>> Hi Erik,<br>
>><br>
>> Thank you very much. With that clue the compilation now doesn’t fail at that particular point.<br>
>><br>
>> The bad news is it now fails to compile this module<br>
>><br>
>> <a href="https://hackage.haskell.org/package/yarr-1.3.2/docs/src/Data-Yarr-Utils-Primitive.html#clampM%27" target="_blank">https://hackage.haskell.org/package/yarr-1.3.2/docs/src/Data-Yarr-Utils-Primitive.html#clampM%27</a><br>
>><br>
>> with a parse error(!). Not only do I not have much experience with TH but this has now exposed my ignorance of CPP.<br>
>><br>
>>> Data/Yarr/Utils/Primitive.hs:119:126: Parse error in pattern: con<br>
>><br>
>> If I comment out the last four lines<br>
>><br>
>>> PRIM_COMP_INST(Int, I#, (<=#), (>=#))<br>
>>> PRIM_COMP_INST(Char, C#, leChar#, geChar#)<br>
>>> PRIM_COMP_INST(Word, W#, leWord#, geWord#)<br>
>>> PRIM_COMP_INST(Double, D#, (<=##), (>=##))<br>
>>> PRIM_COMP_INST(Float, F#, leFloat#, geFloat#)<br>
>><br>
>> then the module compiles but of course then the whole package does *not* compile.<br>
>><br>
>> Did something change in 7.8.3 with regard to CPP (this code has not been modified for at least two years)?<br>
>><br>
>> Thanks once again.<br>
>><br>
>> Dominic Steinitz<br>
>> <a href="mailto:dominic@steinitz.org">dominic@steinitz.org</a><br>
>> <a href="http://idontgetoutmuch.wordpress.com" target="_blank">http://idontgetoutmuch.wordpress.com</a><br>
>><br>
>> On 23 Dec 2014, at 13:42, Erik Hesselink <<a href="mailto:hesselink@gmail.com">hesselink@gmail.com</a>> wrote:<br>
>><br>
>>> Hi Dominic,<br>
>>><br>
>>> It looks like just a representation change: a TySynEqn is a data type<br>
>>> containing a [Type] and a Type, and those were the original two<br>
>>> arguments. So it looks like with a little bit of CPP, you could<br>
>>> support both versions. Something like<br>
>>><br>
>>> #if MIN_VERSION_template_haskell(2,9,0)<br>
>>> ...<br>
>>> #else<br>
>>> ...<br>
>>> #endif<br>
>>><br>
>>> In general, I think each major release of template haskell has quite<br>
>>> some breaking changes, but I don't know of any place where they're<br>
>>> enumerated. The GHC changelog only has a couple of high level bullet<br>
>>> points.<br>
>>><br>
>>> Regards,<br>
>>><br>
>>> Erik<br>
>>><br>
>>> On Tue, Dec 23, 2014 at 2:20 PM, Dominic Steinitz <<a href="mailto:dominic@steinitz.org">dominic@steinitz.org</a>> wrote:<br>
>>>> I realise I should have sent this to the libraries list.<br>
>>>><br>
>>>> Dominic Steinitz<br>
>>>> <a href="mailto:dominic@steinitz.org">dominic@steinitz.org</a><br>
>>>> <a href="http://idontgetoutmuch.wordpress.com" target="_blank">http://idontgetoutmuch.wordpress.com</a><br>
>>>><br>
>>>> Begin forwarded message:<br>
>>>><br>
>>>> From: Dominic Steinitz <<a href="mailto:dominic@steinitz.org">dominic@steinitz.org</a>><br>
>>>> Subject: Latest Template Haskell Breaks Package<br>
>>>> Date: 23 December 2014 13:14:26 GMT<br>
>>>> To: Haskell-Cafe <<a href="mailto:haskell-cafe@haskell.org">haskell-cafe@haskell.org</a>><br>
>>>><br>
>>>> Hello Fellow Haskellers,<br>
>>>><br>
>>>> I have become a maintainer for yarr<br>
>>>> (<a href="https://hackage.haskell.org/package/yarr" target="_blank">https://hackage.haskell.org/package/yarr</a>). This no longer compiles with<br>
>>>> ghc-7.8.3 because it specifies base == 4.6. Relaxing this to base >=4.6 &&<br>
>>>> <4.8 tells me I need a newer version of Template Haskell<br>
>>>><br>
>>>> rejecting: template-haskell-2.7.0.0, 2.6.0.0, 2.5.0.0, 2.4.0.1, 2.4.0.0,<br>
>>>> 2.3.0.1, 2.3.0.0, 2.2.0.0 (conflict: yarr => template-haskell>=2.8 && <2.9)<br>
>>>><br>
>>>><br>
>>>> If I now relax the constraint for Template Haskell I get a compiler error as<br>
>>>> there has been a breaking change from Template Haskell 2.9 to 2.10.<br>
>>>><br>
>>>> Data/Yarr/Utils/FixedVector/VecTuple.hs:45:16:<br>
>>>>   Couldn't match expected type ‘TypeQ -> Q Dec’<br>
>>>>               with actual type ‘Q Dec’<br>
>>>>   The function ‘tySynInstD’ is applied to three arguments,<br>
>>>>   but its type ‘Name -> TySynEqnQ -> DecQ’ has only two<br>
>>>><br>
>>>><br>
>>>> And indeed looking at the changes in<br>
>>>> <a href="http://git.haskell.org/packages/template-haskell.git/commitdiff/ccd7891c536b29b8bea96eb92520f46e21390e39" target="_blank">http://git.haskell.org/packages/template-haskell.git/commitdiff/ccd7891c536b29b8bea96eb92520f46e21390e39</a><br>
>>>> I can see that the function in question has changed.<br>
>>>><br>
>>>> -tySynInstD :: Name -> [TypeQ] -> TypeQ -> DecQ<br>
>>>> -tySynInstD tc tys rhs =<br>
>>>> +tySynInstD :: Name -> [TySynEqnQ] -> DecQ<br>
>>>> +tySynInstD tc eqns =<br>
>>>><br>
>>>><br>
>>>> Did I miss some announcement of this breaking change and the advice on what<br>
>>>> to do about it?<br>
>>>><br>
>>>> If I did can someone please point me at the relevant document. If not then I<br>
>>>> feel sad and would be very grateful if someone could help me as I know very<br>
>>>> little about Template Haskell.<br>
>>>><br>
>>>> Many thanks<br>
>>>><br>
>>>> Dominic Steinitz<br>
>>>> <a href="mailto:dominic@steinitz.org">dominic@steinitz.org</a><br>
>>>> <a href="http://idontgetoutmuch.wordpress.com" target="_blank">http://idontgetoutmuch.wordpress.com</a><br>
>>>><br>
>>>><br>
>>>><br>
>>>> _______________________________________________<br>
>>>> Libraries mailing list<br>
>>>> <a href="mailto:Libraries@haskell.org">Libraries@haskell.org</a><br>
>>>> <a href="http://www.haskell.org/mailman/listinfo/libraries" target="_blank">http://www.haskell.org/mailman/listinfo/libraries</a><br>
>>>><br>
>><br>
<br>
_______________________________________________<br>
Libraries mailing list<br>
<a href="mailto:Libraries@haskell.org">Libraries@haskell.org</a><br>
<a href="http://www.haskell.org/mailman/listinfo/libraries" target="_blank">http://www.haskell.org/mailman/listinfo/libraries</a><br>
</div></div></blockquote></div><br></div>