File tree Expand file tree Collapse file tree 2 files changed +5
-0
lines changed Expand file tree Collapse file tree 2 files changed +5
-0
lines changed Original file line number Diff line number Diff line change @@ -7,6 +7,7 @@ Notable changes to this project are documented in this file. The format is based
77Breaking changes:
88
99New features:
10+ - Add ` prependArray ` (#224 by @JordanMartinez )
1011
1112Bugfixes:
1213
Original file line number Diff line number Diff line change @@ -21,6 +21,7 @@ module Data.Array.NonEmpty
2121 , snoc
2222 , snoc'
2323 , appendArray
24+ , prependArray
2425 , insert
2526 , insertBy
2627
@@ -233,6 +234,9 @@ snoc' xs x = unsafeFromArray $ A.snoc xs x
233234appendArray :: forall a . NonEmptyArray a -> Array a -> NonEmptyArray a
234235appendArray xs ys = unsafeFromArray $ toArray xs <> ys
235236
237+ prependArray :: forall a . Array a -> NonEmptyArray a -> NonEmptyArray a
238+ prependArray xs ys = unsafeFromArray $ xs <> toArray ys
239+
236240insert :: forall a . Ord a => a -> NonEmptyArray a -> NonEmptyArray a
237241insert x = unsafeAdapt $ A .insert x
238242
You can’t perform that action at this time.
0 commit comments