[Haskell-beginners] A first try

David Place d at vidplace.com
Sun Jun 26 23:32:02 CEST 2011



On Jun 26, 2011, at 4:59 PM, Manfred Lotz wrote:

> Is there any problem in the code snippet I pasted? If so I would
> like to get a hint of course.

There really isn't enough code in your snippet to be able to say.  The rule is that if you return a lazy data structure from withFile you may find the file has been closed before you have read the data.  If your parseXMLDoc is strict then you will get away with it.   I feel that isn't very nice.

____________________
David Place   
Owner, Panpipes Ho! LLC
http://panpipesho.com
d at vidplace.com




More information about the Beginners mailing list