diff options
author | Viktor Dukhovni <ietf-dane@dukhovni.org> | 2021-12-08 15:29:26 -0500 |
---|---|---|
committer | Marge Bot <ben+marge-bot@smart-cactus.org> | 2021-12-09 04:27:48 -0500 |
commit | d6177cb5dac357ff15ae048556f03039dd6987d2 (patch) | |
tree | 98a830e4265a64f540231949a3b2fcee1f880f44 | |
parent | a722859f1989a826b2b0701ddc68faad8e85b84e (diff) | |
download | haskell-d6177cb5dac357ff15ae048556f03039dd6987d2.tar.gz |
Drop O(n^2) warning on concat
-rw-r--r-- | libraries/base/Data/Foldable.hs | 3 |
1 files changed, 0 insertions, 3 deletions
diff --git a/libraries/base/Data/Foldable.hs b/libraries/base/Data/Foldable.hs index d17f152391..373f1b4529 100644 --- a/libraries/base/Data/Foldable.hs +++ b/libraries/base/Data/Foldable.hs @@ -1211,9 +1211,6 @@ msum = asum -- -- >>> concat [[1, 2, 3], [4, 5], [6], []] -- [1,2,3,4,5,6] --- --- WARNING: This function takes O(n^2) time in the total number of elements --- when the 't' is '[]'. concat :: Foldable t => t [a] -> [a] concat xs = build (\c n -> foldr (\x y -> foldr c y x) n xs) {-# INLINE concat #-} |