aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--CHANGELOG.md4
-rw-r--r--src/gleam/bool.gleam2
2 files changed, 6 insertions, 0 deletions
diff --git a/CHANGELOG.md b/CHANGELOG.md
index a756cc7..574f0c8 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -8,6 +8,10 @@
- `list.LengthMismatch` has been removed.
- The mistakenly public `bit_array.do_inspect` function has been removed.
- Fixed the `dynamic.classification` function for bools.
+- The `min` function in the `bool` module has been deprecated in favour of
+ `bool.and`.
+- The `max` function in the `bool` module has been deprecated in favour of
+ `bool.or`.
## v0.36.0 - 2024-02-26
diff --git a/src/gleam/bool.gleam b/src/gleam/bool.gleam
index 0671c03..4192ac5 100644
--- a/src/gleam/bool.gleam
+++ b/src/gleam/bool.gleam
@@ -253,6 +253,7 @@ pub fn compare(a: Bool, with b: Bool) -> Order {
/// // -> False
/// ```
///
+@deprecated("Use the `bool.or` function instead")
pub fn max(a: Bool, b: Bool) -> Bool {
case a {
True -> True
@@ -279,6 +280,7 @@ pub fn max(a: Bool, b: Bool) -> Bool {
/// // -> False
/// ```
///
+@deprecated("Use the `bool.and` function instead")
pub fn min(a: Bool, b: Bool) -> Bool {
case a {
False -> False