# OPTIONS_GHC -cpp #
-----------------------------------------------------------------------------
-- |
  Module       :   Distribution . Compat . ReadP
  Copyright    :   ( c ) The University of Glasgow 2002
-- License     :  BSD-style (see the file libraries/base/LICENSE)
-- 
-- Maintainer  :  
-- Stability   :  provisional
-- Portability :  portable
--
  This is a library of parser combinators , originally written by   .
-- It parses all alternatives in parallel, so it never keeps hold of 
-- the beginning of the input string, a common source of space leaks with
-- other parsers.  The '(+++)' choice combinator is genuinely commutative;
-- it makes no difference which branch is \"shorter\".
--
  See also  's paper /Parallel  
-- (</~koen/publications.html>).
--
  This version of ReadP has been locally hacked to make it H98 , by
    < mailto: >
--
-----------------------------------------------------------------------------

module Distribution.Compat.ReadP
  ( 
  -- * The 'ReadP' type
  : : * - > * ; instance Functor , Monad , MonadPlus
  
  -- * Primitive operations
  : :  
  look,       -- :: ReadP String
  (+++),      -- :: ReadP a -> ReadP a -> ReadP a
  (<++),      -- :: ReadP a -> ReadP a -> ReadP a
  gather,     -- :: ReadP a -> ReadP (String, a)
  
  -- * Other operations
  pfail,      -- :: ReadP a
  : : (    Bool ) - > ReadP Char
  : :    ReadP Char
  string,     -- :: String -> ReadP String
  : : (    Bool ) - > ReadP String
  : : (    Bool ) - > ReadP String
  : :  ( )
  choice,     -- :: [ReadP a] -> ReadP a
  count,      -- :: Int -> ReadP a -> ReadP [a]
  between,    -- :: ReadP open -> ReadP close -> ReadP a -> ReadP a
  option,     -- :: a -> ReadP a -> ReadP a
  optional,   -- :: ReadP a -> ReadP ()
  many,       -- :: ReadP a -> ReadP [a]
  many1,      -- :: ReadP a -> ReadP [a]
  skipMany,   -- :: ReadP a -> ReadP ()
  skipMany1,  -- :: ReadP a -> ReadP ()
  sepBy,      -- :: ReadP a -> ReadP sep -> ReadP [a]
  sepBy1,     -- :: ReadP a -> ReadP sep -> ReadP [a]
  endBy,      -- :: ReadP a -> ReadP sep -> ReadP [a]
  endBy1,     -- :: ReadP a -> ReadP sep -> ReadP [a]
  chainr,     -- :: ReadP a -> ReadP (a -> a -> a) -> a -> ReadP a
  chainl,     -- :: ReadP a -> ReadP (a -> a -> a) -> a -> ReadP a
  chainl1,    -- :: ReadP a -> ReadP (a -> a -> a) -> ReadP a
  chainr1,    -- :: ReadP a -> ReadP (a -> a -> a) -> ReadP a
  manyTill,   -- :: ReadP a -> ReadP end -> ReadP [a]
  
  -- * Running a parser
  ReadS,      -- :: *; = String -> [(a,String)]
  readP_to_S, -- :: ReadP a -> ReadS a
  readS_to_P  -- :: ReadS a -> ReadP a
  




  )
 where



import Text.ParserCombinators.ReadP hiding (ReadP)
import qualified Text.ParserCombinators.ReadP as ReadP

type ReadP r a = ReadP.ReadP a


















































































































































































































































































































































































































---------------------------------------------------------------------------
 |
 License     :  BSD-style (see the file libraries/base/LICENSE)
 
 Maintainer  :  
 Stability   :  provisional
 Portability :  portable

 It parses all alternatives in parallel, so it never keeps hold of 
 the beginning of the input string, a common source of space leaks with
 other parsers.  The '(+++)' choice combinator is genuinely commutative;
 it makes no difference which branch is \"shorter\".

 (</~koen/publications.html>).


---------------------------------------------------------------------------
 * The 'ReadP' type
 * Primitive operations
 :: ReadP String
 :: ReadP a -> ReadP a -> ReadP a
 :: ReadP a -> ReadP a -> ReadP a
 :: ReadP a -> ReadP (String, a)
 * Other operations
 :: ReadP a
 :: String -> ReadP String
 :: [ReadP a] -> ReadP a
 :: Int -> ReadP a -> ReadP [a]
 :: ReadP open -> ReadP close -> ReadP a -> ReadP a
 :: a -> ReadP a -> ReadP a
 :: ReadP a -> ReadP ()
 :: ReadP a -> ReadP [a]
 :: ReadP a -> ReadP [a]
 :: ReadP a -> ReadP ()
 :: ReadP a -> ReadP ()
 :: ReadP a -> ReadP sep -> ReadP [a]
 :: ReadP a -> ReadP sep -> ReadP [a]
 :: ReadP a -> ReadP sep -> ReadP [a]
 :: ReadP a -> ReadP sep -> ReadP [a]
 :: ReadP a -> ReadP (a -> a -> a) -> a -> ReadP a
 :: ReadP a -> ReadP (a -> a -> a) -> a -> ReadP a
 :: ReadP a -> ReadP (a -> a -> a) -> ReadP a
 :: ReadP a -> ReadP (a -> a -> a) -> ReadP a
 :: ReadP a -> ReadP end -> ReadP [a]
 * Running a parser
 :: *; = String -> [(a,String)]
 :: ReadP a -> ReadS a
 :: ReadS a -> ReadP a
# OPTIONS_GHC -cpp #
  Module       :   Distribution . Compat . ReadP
  Copyright    :   ( c ) The University of Glasgow 2002
  This is a library of parser combinators , originally written by   .
  See also  's paper /Parallel  
  This version of ReadP has been locally hacked to make it H98 , by
    < mailto: >

module Distribution.Compat.ReadP
  ( 
  : : * - > * ; instance Functor , Monad , MonadPlus
  
  : :  
  
  : : (    Bool ) - > ReadP Char
  : :    ReadP Char
  : : (    Bool ) - > ReadP String
  : : (    Bool ) - > ReadP String
  : :  ( )
  
  




  )
 where



import Text.ParserCombinators.ReadP hiding (ReadP)
import qualified Text.ParserCombinators.ReadP as ReadP

type ReadP r a = ReadP.ReadP a

















































































































































































































































































































































































































