X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=GHC%2FRead.lhs;h=bfffb19f5cbcccc8b6da577166d3e56572929bb2;hb=75ea0fa2485c169f0546d5d40477d2f6747efe29;hp=38a2ccf189e0f3192c2890a37cf384ca011f33e9;hpb=5803fbf18934b2e3f5b911002a405b54f3afdb22;p=ghc-base.git diff --git a/GHC/Read.lhs b/GHC/Read.lhs index 38a2ccf..bfffb19 100644 --- a/GHC/Read.lhs +++ b/GHC/Read.lhs @@ -107,7 +107,9 @@ type ReadS a = String -> [(a,String)] class Read a where readsPrec :: Int -> ReadS a readList :: ReadS [a] + -- | Proposed replacement for 'readsPrec' using new-style parsers (GHC only). readPrec :: ReadPrec a + -- | Proposed replacement for 'readList' using new-style parsers (GHC only). readListPrec :: ReadPrec [a] -- default definitions @@ -117,13 +119,13 @@ class Read a where readListPrec = readS_to_Prec (\_ -> readList) readListDefault :: Read a => ReadS [a] --- ^ Use this to define the 'readList' method, if you --- don't want a special case +-- ^ Use this to define the 'readList' method, if you don't want a special +-- case (GHC only; for other systems the default suffices). readListDefault = readPrec_to_S readListPrec 0 readListPrecDefault :: Read a => ReadPrec [a] -- ^ Use this to define the 'readListPrec' method, if you --- don't want a special case +-- don't want a special case (GHC only). readListPrecDefault = list readPrec ------------------------------------------------------------------------