on master help sign in
Fix dates/typo/Functor instance
commit94459757ddf725fbdc356c5fe4fc733bb0d5857a authorHarendra Kumar <harendra@composewell.com> dateMon 23 Mar 2020, 18:54 (7 years ago) parentc3a7e60
2 files changed+4−7
benchmark/Streamly/Benchmark/Data/Parser.hs+2−2 src/Streamly/Internal/Data/Parser/Types.hs+2−5
benchmark/Streamly/Benchmark/Data/Parser.hs+2−2
@@ -1,6 +1,6 @@
11-- |
2−-- Module : Streamly.Benchmark.Data.Fold
3−-- Copyright : (c) 2018 Composewell
2+-- Module : Streamly.Benchmark.Data.Parser
3+-- Copyright : (c) 2020 Composewell Technologies
44--
55-- License : MIT
66-- Maintainer : streamly@composewell.com
src/Streamly/Internal/Data/Parser/Types.hs+2−5
@@ -33,7 +33,7 @@
3333-- 1. Buffer the input until explicitly asked to drop the input
3434-- 2. Drop the input stream beyond a "point of no return" in the history
3535-- because the input till that point has been consumed irrevocably.
36−-- 2. Go back in the buffered stream upto the point of no return.
36+-- 3. Go back in the buffered stream upto the point of no return.
3737--
3838-- Based on application requirements it should be possible to design even a
3939-- richer interface to manipulate the input stream/buffer. For example, we
@@ -106,7 +106,7 @@ data Parser m a b =
106106
107107-- | Maps a function over the output of the fold.
108108--
109−instance Monad m => Functor (Parser m a) where
109+instance Functor m => Functor (Parser m a) where
110110 {-# INLINE fmap #-}
111111 fmap f (Parser step initial extract) =
112112 Parser step initial (fmap3 f extract)
@@ -115,9 +115,6 @@ instance Monad m => Functor (Parser m a) where
115115
116116 fmap3 g = fmap (fmap (fmap g))
117117
118− {-# INLINE (<$) #-}
119− (<$) b = \_ -> pure b
120−
121118{-# ANN type SeqParseState Fuse #-}
122119data SeqParseState sl f sr =
123120 SeqParseL sl | SeqParseR f sr | SeqParseLErr String