[Haskell-cafe] hSeek in Windows

Philippos Apolinarius phi500ac at yahoo.ca
Sun Nov 1 15:44:42 EST 2009


As many people guess, I am trying to port programs from Clean 1.3 to Haskell (and also to Clean 2.2, which is easier, but not much easier). Late Professor Wellesley wrote an interesting data base manager in Clean 1.3 that I would like to see in Haskell and Clean 2.2. However, when I tried to implement the BTree algorithm, GHC compiler did not accept hSeek and other IO operations.

D:\Programs\GHC-PROGS\docs\textut>ghc btree.hs --make
[1 of 1] Compiling Main             ( btree.hs, btree.o )
Linking btree.exe ...

D:\Programs\GHC-PROGS\docs\textut>btree.exe
btree.exe: teste.txt: hSeek: illegal operation (seek operations on text-mod
dles are not allowed on this platform)

To make a long story short, the program compiles, but does not run. This is interesting, because when Clean compiles an input/output operation it certainly executes it. In any case, what I should do in order to make file operations work on Windows? I need random access to text files. 




      __________________________________________________________________
Yahoo! Canada Toolbar: Search from anywhere on the web, and bookmark your favourite sites. Download it now
http://ca.toolbar.yahoo.com.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.haskell.org/pipermail/haskell-cafe/attachments/20091101/205f93af/attachment.html


More information about the Haskell-Cafe mailing list