Re: [Haskell-cafe] Data.Binary, Data.Text and errors

2009-03-21 Thread Alexander Dunlap
On Sun, Mar 15, 2009 at 9:13 PM, Bryan O'Sullivan b...@serpentine.com wrote: On Sun, Mar 15, 2009 at 8:40 PM, Alexander Dunlap alexander.dun...@gmail.com wrote: I have noticed that in both Data.Binary and Data.Text (which is still experimental, but still), the decode functions can be

Re: [Haskell-cafe] Data.Binary, Data.Text and errors

2009-03-16 Thread Khudyakov Alexey
On Monday 16 March 2009 06:40:12 Alexander Dunlap wrote: Hi all, I have noticed that in both Data.Binary and Data.Text (which is still experimental, but still), the decode functions can be undefined (i.e. bottom) if they encounter malformed input. What is the preferred way to use these

[Haskell-cafe] Data.Binary, Data.Text and errors

2009-03-15 Thread Alexander Dunlap
Hi all, I have noticed that in both Data.Binary and Data.Text (which is still experimental, but still), the decode functions can be undefined (i.e. bottom) if they encounter malformed input. What is the preferred way to use these functions in a safe way? For example, if one writes data to a disk

Re: [Haskell-cafe] Data.Binary, Data.Text and errors

2009-03-15 Thread Bryan O'Sullivan
On Sun, Mar 15, 2009 at 8:40 PM, Alexander Dunlap alexander.dun...@gmail.com wrote: I have noticed that in both Data.Binary and Data.Text (which is still experimental, but still), the decode functions can be undefined (i.e. bottom) if they encounter malformed input. For decoding Unicode,