[Haskell-cafe] Trouble compiling Data.PriorityQueue?

David Banas capn.freako at gmail.com
Sat May 22 18:24:23 UTC 2021

Has anyone else bumped into this compilation error when trying to use Data.PriorityQueue?

Building library for priority-queue-0.2.1..
[1 of 1] Compiling Data.PriorityQueue ( src/Data/PriorityQueue.hs, dist/build/Data/PriorityQueue.o )

src/Data/PriorityQueue.hs:120:50-54: error:
    Ambiguous occurrence ‘unzip’
    It could refer to either ‘List.unzip’,
                             imported from ‘Data.List’ at src/Data/PriorityQueue.hs:55:1-24
                             (and originally defined in ‘GHC.List’)
                          or ‘Seq.unzip’,
                             imported from ‘Data.Sequence’ at src/Data/PriorityQueue.hs:54:1-27
                             (and originally defined in ‘Data.Sequence.Internal’)
120 |             batches = map ((head *** fromList) . unzip) grouped
    |                                                  ^^^^^
cabal: Failed to build priority-queue-0.2.1 (which is required by exe:ex1 from
haskarch- See the build log above for details.


More information about the Haskell-Cafe mailing list