[Haskell-beginners] Data.Vector in Haskell

Dananji Liyanage dan9131 at gmail.com
Wed May 27 08:15:13 UTC 2015


Hi All,

I'm trying to extract elements from a Vector using 'head' and 'tail'
function in Data.Vector package, but it gives me the following error now.

<interactive>:41:18:
    Couldn't match expected type ‘Data.Vector.Vector a’
                with actual type ‘vector-0.10.9.1:Data.Vector.Vector Int’
    NB: ‘Data.Vector.Vector’
          is defined in ‘Data.Vector’ in package ‘vector-0.10.12.3’
        ‘vector-0.10.9.1:Data.Vector.Vector’
          is defined in ‘Data.Vector’ in package ‘vector-0.10.9.1’
    Relevant bindings include it :: a (bound at <interactive>:41:1)
    In the first argument of ‘Data.Vector.head’, namely ‘it’
    In the expression: Data.Vector.head it

It was working fine before.

Any help would be appreciated. Thanks in advance!

-- 
Regards,
Dananji Liyanage
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/beginners/attachments/20150527/82470e28/attachment-0001.html>


More information about the Beginners mailing list