Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What does the <> operator mean

What does the operator <> mean/do in the following code?

class Functor f => Foldable f where
    fold    :: Monoid m =>             f m -> m
    foldMap :: Monoid m => (a -> m) -> f a -> m

instance Foldable [] where
    fold = foldr (<>) mempty

Can anyone tell me?

like image 902
Skyfe Avatar asked Feb 15 '23 00:02

Skyfe


1 Answers

It's an operator from Data.Monoid:

(<>) = mappend‌​

You can often Hoogle or Hayoo for such operators.

like image 118
Fixnum Avatar answered Feb 23 '23 17:02

Fixnum