Skip to content
Snippets Groups Projects
Commit fc85ec26 authored by Jens Nolte's avatar Jens Nolte
Browse files

Add lifted semigroup operator

parent dae04f4c
No related branches found
No related tags found
No related merge requests found
Pipeline #2301 passed
......@@ -8,6 +8,7 @@ import "base" Prelude
import Quasar.Utils.ExtraT
import Control.Applicative (liftA2)
import Control.Monad.State.Lazy as State
import qualified Data.Char as Char
import qualified Data.Hashable as Hashable
......@@ -80,5 +81,9 @@ infixl 4 <<$>>
(<<$>>) :: (Functor f, Functor g) => (a -> b) -> f (g a) -> f (g b)
(<<$>>) = fmap . fmap
infixr 6 <<>>
(<<>>) :: (Applicative f, Semigroup a) => f a -> f a -> f a
(<<>>) = liftA2 (<>)
dup :: a -> (a, a)
dup x = (x, x)
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment