aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--CHANGELOG.md10
-rw-r--r--src/gleam/list.gleam2
2 files changed, 8 insertions, 4 deletions
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 5252792..d06ab08 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -2,10 +2,14 @@
## Unreleased
-- The `dynamic` module gains the `tuple3`, `tuple4`, `tuple5`, `tuple6` functions and
- their typed equivalents `typed_tuple3`, `typed_tuple4`, `typed_tuple5`, `typed_tuple6`.
+- The `list.split_while` function's second argument now has the label
+`satisfying` to match the other `_while` functions in `list` and `iterator`.
+- The `dynamic` module gains the `tuple3`, `tuple4`, `tuple5`, `tuple6`
+ functions and their typed equivalents `typed_tuple3`, `typed_tuple4`,
+ `typed_tuple5`, `typed_tuple6`.
- The `list` modules gains the `drop_while` and `take_while` functions.
-- The `iterator` module gains the `index`, `iterate`, `zip`, `scan`, `take_while` and `drop_while` functions.
+- The `iterator` module gains the `index`, `iterate`, `zip`, `scan`,
+ `take_while` and `drop_while` functions.
## v0.14.0 - 2021-02-18
diff --git a/src/gleam/list.gleam b/src/gleam/list.gleam
index 7317242..1f430ad 100644
--- a/src/gleam/list.gleam
+++ b/src/gleam/list.gleam
@@ -960,7 +960,7 @@ fn do_split_while(
///
pub fn split_while(
list list: List(a),
- while predicate: fn(a) -> Bool,
+ satisfying predicate: fn(a) -> Bool,
) -> tuple(List(a), List(a)) {
do_split_while(list, predicate, [])
}