Skip to content

Copar doesn't compile with primitive-0.7.1.0

Error:

src/Copar/Functors/AbsorbingPolynomial.hs:149:10: error:
    Duplicate instance declarations:
      instance NFData a => NFData (SmallArray a)
        -- Defined at src/Copar/Functors/AbsorbingPolynomial.hs:149:10
      instance NFData a => NFData (SmallArray a)
        -- Defined in ‘Data.Primitive.SmallArray’
    |
149 | instance NFData a => NFData (SmallArray a) where
    |

From their changelog:

Add NFData instances for ByteArray, MutableByteArray, PrimArray and MutablePrimArray. by Callan McGill

We need to either introduce a lower bound on this version, pin it to the old one or add an ifdef. I'd favor the first option.