diff options
author | Louis Pilfold <louis@lpil.uk> | 2019-03-15 14:50:11 +0000 |
---|---|---|
committer | Louis Pilfold <louis@lpil.uk> | 2019-03-15 14:54:02 +0000 |
commit | d613e26ebd67b704ab58c28cc559ee01ae03b547 (patch) | |
tree | 96e484695221b0a39dee2ffc51aa0c0b7249d87e /src/bool.gleam | |
parent | 1ce9a14ba69c593bb40998a5a49d3f066a4aa07a (diff) | |
download | gleam_stdlib-d613e26ebd67b704ab58c28cc559ee01ae03b547.tar.gz gleam_stdlib-d613e26ebd67b704ab58c28cc559ee01ae03b547.zip |
Erase directly called capture funs
Diffstat (limited to 'src/bool.gleam')
-rw-r--r-- | src/bool.gleam | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/src/bool.gleam b/src/bool.gleam index 84e5f6c..89d39f0 100644 --- a/src/bool.gleam +++ b/src/bool.gleam @@ -1,20 +1,20 @@ import expect import order -// pub fn not(bool) { -// case bool { -// | True -> False -// | False -> True -// } -// } +pub fn negate(bool) { + case bool { + | True -> False + | False -> True + } +} -// test not { -// not(True) -// |> expect:false +test negate { + negate(True) + |> expect:false -// not(False) -// |> expect:true -// } + negate(False) + |> expect:true +} // pub fn compare(a, b) { // case {a, b} { |