Hi,I’me writing a simple parser and can test it in GHCIparseTest moveParser "(1,2)->(3,3)”and I get what I expect i.e.Move {from = Location 1 2, to = Location 3 3}I now have a text file (test.txt) with lots of (1,2)->(3,3) (3,6)->(3,9) etc etc andI really can’t see how I get the contents of the text file into the parser!!I havemain = dohandle <- openFile "test.txt" ReadModecontents <- hGetContents handle!! what goes here!!! - how do I invoke moveParser with contents ??ThanksMike
_______________________________________________
Beginners mailing list
Beginners@haskell.org
http://mail.haskell.org/cgi-bin/mailman/listinfo/beginners