Permalink
Browse files

Improve error message.

  • Loading branch information...
1 parent 6cff0e0 commit 3b0634bc866fd22175ef236ea3c61b147bb10290 @bos committed Mar 16, 2011
Showing with 2 additions and 1 deletion.
  1. +2 −1 Data/Text/Encoding.hs
View
3 Data/Text/Encoding.hs
@@ -120,7 +120,8 @@ decodeUtf8With onErr bs = textP (fst a) 0 (snd a)
desc = "Data.Text.Encoding.decodeUtf8: Invalid UTF-8 stream"
{-# INLINE[0] decodeUtf8With #-}
--- | Decode a 'ByteString' containing known-valid UTF-8 encoded text.
+-- | Decode a 'ByteString' containing UTF-8 encoded text that is known
+-- to be valid.
--
-- If the input contains any invalid UTF-8 data, an exception will be
-- thrown that cannot be caught in pure code. For more control over

0 comments on commit 3b0634b

Please sign in to comment.