开发者

Haskell: Cannot use dropWhileEnd, modules Data.Text.Lazy/Data.Lazy not found

First I have to admit: I am totally new to Haskell. I have practiced a bit with it and now have some trouble concerning string-manipulation:

I need to erase/drop ch开发者_开发百科aracters beginning from the end of a string. I expected the function dropWhileEnd to do this, but when I try to import Data.Text.Lazy or Data.Lazy, ghc tells me it couldn't find those modules.

My question is: why doesn't ghc find them? Shouldn't they be in the standard library? I am using Haskell Platform 2010.2.0.0 with the included ghc on Windows.


The 'text' package is part of the Haskell Platform 2011.2 -- it was only added this year. You have two choices:

Stay with 2010.2, and install the text package:

  • cabal install text

Upgrade to 2011.2 here:

  • http://haskell.org/platform
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜