Supplies an attoparsec Parser with an InputStream, returning the
final parsed value or throwing a ParseException if parsing fails.
parseFromStream consumes only as much input as necessary to satisfy the Parser: any unconsumed input is pushed back onto the InputStream.
If the Parser exhausts the InputStream, the end-of-stream signal is sent to attoparsec.
Example:
ghci> import Data.Attoparsec.ByteString.Char8
ghci> is <- System.IO.Streams.fromList ["12345xxx" :: ByteString]
ghci> parseFromStream (takeWhile isDigit) is
"12345"
ghci> System.IO.Streams.read is
Just "xxx"