dhall-nix-lib/Integer/isZero.dhall

13 lines
302 B
Text

let Integer/nonPositive = ./nonPositive.dhall
let Integer/nonNegative = ./nonNegative.dhall
let isZero
: Integer → Bool
= λ(v : Integer) → Integer/nonPositive v && Integer/nonNegative v
let example0 = assert : isZero +2 ≡ False
let example1 = assert : isZero +0 ≡ True
in isZero