[Git][ghc/ghc][master] fix: Change type signatures in NonEmpty export comments to reflect reality
Marge Bot (@marge-bot)
gitlab at gitlab.haskell.org
Wed Nov 22 16:48:56 UTC 2023
Marge Bot pushed to branch master at Glasgow Haskell Compiler / GHC
Commits:
17ec3e97 by Owen Shepherd at 2023-11-22T09:37:28+01:00
fix: Change type signatures in NonEmpty export comments to reflect reality
This fixes several typos in the comments of
Data.List.NonEmpty export list items.
- - - - -
1 changed file:
- libraries/base/src/Data/List/NonEmpty.hs
Changes:
=====================================
libraries/base/src/Data/List/NonEmpty.hs
=====================================
@@ -44,11 +44,11 @@ module Data.List.NonEmpty (
, (<|), cons -- :: a -> NonEmpty a -> NonEmpty a
, uncons -- :: NonEmpty a -> (a, Maybe (NonEmpty a))
, unfoldr -- :: (a -> (b, Maybe a)) -> a -> NonEmpty b
- , sort -- :: NonEmpty a -> NonEmpty a
+ , sort -- :: Ord a => NonEmpty a -> NonEmpty a
, reverse -- :: NonEmpty a -> NonEmpty a
- , inits -- :: Foldable f => f a -> NonEmpty a
+ , inits -- :: Foldable f => f a -> NonEmpty [a]
, inits1 -- :: NonEmpty a -> NonEmpty (NonEmpty a)
- , tails -- :: Foldable f => f a -> NonEmpty a
+ , tails -- :: Foldable f => f a -> NonEmpty [a]
, tails1 -- :: NonEmpty a -> NonEmpty (NonEmpty a)
, append -- :: NonEmpty a -> NonEmpty a -> NonEmpty a
, appendList -- :: NonEmpty a -> [a] -> NonEmpty a
@@ -57,31 +57,31 @@ module Data.List.NonEmpty (
, iterate -- :: (a -> a) -> a -> NonEmpty a
, repeat -- :: a -> NonEmpty a
, cycle -- :: NonEmpty a -> NonEmpty a
- , unfold -- :: (a -> (b, Maybe a) -> a -> NonEmpty b
+ , unfold -- :: (a -> (b, Maybe a)) -> a -> NonEmpty b
, insert -- :: (Foldable f, Ord a) => a -> f a -> NonEmpty a
, some1 -- :: Alternative f => f a -> f (NonEmpty a)
-- * Extracting sublists
, take -- :: Int -> NonEmpty a -> [a]
, drop -- :: Int -> NonEmpty a -> [a]
, splitAt -- :: Int -> NonEmpty a -> ([a], [a])
- , takeWhile -- :: Int -> NonEmpty a -> [a]
- , dropWhile -- :: Int -> NonEmpty a -> [a]
- , span -- :: Int -> NonEmpty a -> ([a],[a])
- , break -- :: Int -> NonEmpty a -> ([a],[a])
+ , takeWhile -- :: (a -> Bool) -> NonEmpty a -> [a]
+ , dropWhile -- :: (a -> Bool) -> NonEmpty a -> [a]
+ , span -- :: (a -> Bool) -> NonEmpty a -> ([a], [a])
+ , break -- :: (a -> Bool) -> NonEmpty a -> ([a], [a])
, filter -- :: (a -> Bool) -> NonEmpty a -> [a]
, partition -- :: (a -> Bool) -> NonEmpty a -> ([a],[a])
- , group -- :: Foldable f => Eq a => f a -> [NonEmpty a]
+ , group -- :: (Foldable f, Eq a) => f a -> [NonEmpty a]
, groupBy -- :: Foldable f => (a -> a -> Bool) -> f a -> [NonEmpty a]
, groupWith -- :: (Foldable f, Eq b) => (a -> b) -> f a -> [NonEmpty a]
- , groupAllWith -- :: (Foldable f, Ord b) => (a -> b) -> f a -> [NonEmpty a]
+ , groupAllWith -- :: Ord b => (a -> b) -> [a] -> [NonEmpty a]
, group1 -- :: Eq a => NonEmpty a -> NonEmpty (NonEmpty a)
, groupBy1 -- :: (a -> a -> Bool) -> NonEmpty a -> NonEmpty (NonEmpty a)
- , groupWith1 -- :: (Foldable f, Eq b) => (a -> b) -> f a -> NonEmpty (NonEmpty a)
- , groupAllWith1 -- :: (Foldable f, Ord b) => (a -> b) -> f a -> NonEmpty (NonEmpty a)
- , permutations
- , permutations1
+ , groupWith1 -- :: Eq b => (a -> b) -> NonEmpty a -> NonEmpty (NonEmpty a)
+ , groupAllWith1 -- :: Ord b => (a -> b) -> NonEmpty a -> NonEmpty (NonEmpty a)
+ , permutations -- :: [a] -> NonEmpty [a]
+ , permutations1 -- :: NonEmpty a -> NonEmpty (NonEmpty a)
-- * Sublist predicates
- , isPrefixOf -- :: Foldable f => f a -> NonEmpty a -> Bool
+ , isPrefixOf -- :: Eq a => [a] -> NonEmpty a -> Bool
-- * \"Set\" operations
, nub -- :: Eq a => NonEmpty a -> NonEmpty a
, nubBy -- :: (a -> a -> Bool) -> NonEmpty a -> NonEmpty a
@@ -90,12 +90,12 @@ module Data.List.NonEmpty (
-- * Zipping and unzipping streams
, zip -- :: NonEmpty a -> NonEmpty b -> NonEmpty (a,b)
, zipWith -- :: (a -> b -> c) -> NonEmpty a -> NonEmpty b -> NonEmpty c
- , unzip -- :: NonEmpty (a, b) -> (NonEmpty a, NonEmpty b)
+ , unzip -- :: Functor f => f (a,b) -> (f a, f b)
-- * Converting to and from a list
, fromList -- :: [a] -> NonEmpty a
, toList -- :: NonEmpty a -> [a]
, nonEmpty -- :: [a] -> Maybe (NonEmpty a)
- , xor -- :: NonEmpty a -> Bool
+ , xor -- :: NonEmpty Bool -> Bool
) where
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/17ec3e97e9862ed2331aa08f54911143db9ad04a
--
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/17ec3e97e9862ed2331aa08f54911143db9ad04a
You're receiving this email because of your account on gitlab.haskell.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/ghc-commits/attachments/20231122/caf103a6/attachment-0001.html>
More information about the ghc-commits
mailing list