@@ -67,6 +67,7 @@ fmapR f (Done bs r) = Done bs (f r)
6767
6868instance Functor Result where
6969 fmap = fmapR
70+ {-# INLINE fmap #-}
7071
7172newtype Input = I {unI :: B.ByteString}
7273newtype Added = A {unA :: B.ByteString}
@@ -139,6 +140,7 @@ fmapP p m = Parser $ \i0 a0 m0 f k ->
139140
140141instance Functor Parser where
141142 fmap = fmapP
143+ {-# INLINE fmap #-}
142144
143145apP :: Parser (a -> b) -> Parser a -> Parser b
144146apP d e = do
@@ -149,23 +151,29 @@ apP d e = do
149151
150152instance Applicative Parser where
151153 pure = returnP
154+ {-# INLINE pure #-}
152155 (<*>) = apP
156+ {-# INLINE (<*>) #-}
153157
154158 -- These definitions are equal to the defaults, but this
155159 -- way the optimizer doesn't have to work so hard to figure
156160 -- that out.
157161 (*>) = (>>)
162+ {-# INLINE (*>) #-}
158163 x <* y = x >>= \a -> y >> return a
164+ {-# INLINE (<*) #-}
159165
160166instance Monoid (Parser a) where
161167 mempty = failDesc "mempty"
162168 {-# INLINE mempty #-}
163169 mappend = plus
170+ {-# INLINE mappend #-}
164171
165172instance Alternative Parser where
166173 empty = failDesc "empty"
167174 {-# INLINE empty #-}
168175 (<|>) = plus
176+ {-# INLINE (<|>) #-}
169177
170178failDesc :: String -> Parser a
171179failDesc err = Parser (\i0 a0 m0 kf _ks -> kf i0 a0 m0 [] msg)