aboutsummaryrefslogtreecommitdiff
path: root/src/std/order.gleam
diff options
context:
space:
mode:
authorLouis Pilfold <louis@lpil.uk>2019-06-25 22:48:07 +0100
committerLouis Pilfold <louis@lpil.uk>2019-06-25 22:48:07 +0100
commit2c2541750ca4b7b604070c75c18d84be833c97d5 (patch)
treef5e63d941a1c7e2c2d4dff1d81c43fa2766308ae /src/std/order.gleam
parent96c20b8ebf8420fbba75c97fa08eaeb34e8dc394 (diff)
downloadgleam_stdlib-2c2541750ca4b7b604070c75c18d84be833c97d5.tar.gz
gleam_stdlib-2c2541750ca4b7b604070c75c18d84be833c97d5.zip
stdlib namespace std -> gleam
Diffstat (limited to 'src/std/order.gleam')
-rw-r--r--src/std/order.gleam48
1 files changed, 0 insertions, 48 deletions
diff --git a/src/std/order.gleam b/src/std/order.gleam
deleted file mode 100644
index 4d39705..0000000
--- a/src/std/order.gleam
+++ /dev/null
@@ -1,48 +0,0 @@
-pub enum Order =
- | Lt
- | Eq
- | Gt
-;
-
-pub fn reverse(order) {
- case order {
- | Lt -> Gt
- | Eq -> Eq
- | Gt -> Lt
- }
-}
-
-pub fn to_int(order) {
- case order {
- | Lt -> -1
- | Eq -> 0
- | Gt -> 1
- }
-}
-
-pub fn compare(a, b) {
- case {a, b} {
- | {Lt, Lt} -> Eq
- | {Lt, _} -> Lt
- | {Eq, Eq} -> Eq
- | {Gt, Gt} -> Eq
- | {Eq, Gt} -> Lt
- | _ -> Gt
- }
-}
-
-pub fn max(a, b) {
- case {a, b} {
- | {Gt, _} -> Gt
- | {Eq, Lt} -> Eq
- | _ -> b
- }
-}
-
-pub fn min(a, b) {
- case {a, b} {
- | {Lt, _} -> Lt
- | {Eq, Gt} -> Eq
- | _ -> b
- }
-}