scalaprops.Bool.scala Maven / Gradle / Ivy
package scalaprops
final case class Bool private(b: Boolean) {
def is = b
def isNot = !is
def implies[A](p: => A)(implicit A: AsProperty[A]): Property =
Property.implies(b, A.asProperty(p))
}
object Bool {
private[this] val t = Bool(true)
private[this] val f = Bool(false)
def bool(b: Boolean): Bool =
if(b) t else f
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy