text-1.2.2.2: An efficient packed Unicode text type.

Copyright | (c) 2014 Bryan O'Sullivan
License | BSD-style
Maintainer | bos@serpentine.com
Stability | experimental
Portability | GHC
Safe Haskell | Safe
Language | Haskell98

Data.Text.Internal.Read

Description

Common internal functions for reading textual data.

# Documentation

type IReader t a = t -> Either String (a, t) Source #

newtype IParser t a Source #

Constructors

P |

Fields

- runP :: IReader t a

Instances

Monad (IParser t) Source # |
Methods (>>=) :: IParser t a -> (a -> IParser t b) -> IParser t b # (>>) :: IParser t a -> IParser t b -> IParser t b # return :: a -> IParser t a # fail :: String -> IParser t a #
Functor (IParser t) Source # |
Methods fmap :: (a -> b) -> IParser t a -> IParser t b # (<$) :: a -> IParser t b -> IParser t a #
Applicative (IParser t) Source # |
Methods pure :: a -> IParser t a # (<*>) :: IParser t (a -> b) -> IParser t a -> IParser t b # (*>) :: IParser t a -> IParser t b -> IParser t b # (<*) :: IParser t a -> IParser t b -> IParser t a #

data T Source #

Constructors

T !Integer !Int |

digitToInt :: Char -> Int Source #

hexDigitToInt :: Char -> Int Source #

perhaps :: a -> IParser t a -> IParser t a Source #