mirror of
https://github.com/github/semantic.git
synced 2024-12-21 13:51:44 +03:00
Define Sequenceable over [] in terms of GSequenceable over [].
This commit is contained in:
parent
dabffff7d0
commit
f959917ae3
@ -1,5 +1,6 @@
|
||||
module Data.Sequenceable where
|
||||
|
||||
import Data.Sequenceable.Generic
|
||||
import Prologue
|
||||
|
||||
-- Classes
|
||||
@ -10,6 +11,4 @@ class Functor t => Sequenceable t where
|
||||
|
||||
-- Instances
|
||||
|
||||
instance Sequenceable [] where
|
||||
sequenceAlt (x:xs) = ((:) <$> x <|> pure identity) <*> sequenceAlt xs
|
||||
sequenceAlt [] = pure []
|
||||
instance Sequenceable [] where sequenceAlt = gsequenceAlt
|
||||
|
Loading…
Reference in New Issue
Block a user