Hoogle Search
Within LTS Haskell 24.18 (ghc-9.10.3)
Note that Stackage only displays results for the latest LTS and Nightly snapshot. Learn more.
-
classy-prelude ClassyPrelude Case analysis for the Bool type. bool f t p evaluates to f when p is False, and evaluates to t when p is True. This is equivalent to if p then t else f; that is, one can think of it as an if-then-else construct with its arguments reordered.
Examples
Basic usage:>>> bool "foo" "bar" True "bar" >>> bool "foo" "bar" False "foo"
Confirm that bool f t p and if p then t else f are equivalent:>>> let p = True; f = "bar"; t = "foo" >>> bool f t p == if p then t else f True >>> let p = False >>> bool f t p == if p then t else f True
-
glib System.Glib.GTypeConstants No documentation available.
-
wl-pprint-text Text.PrettyPrint.Leijen.Text The document (bool b) shows the literal boolean b using text.
bool :: Applicative m => Bool -> m Docwl-pprint-text Text.PrettyPrint.Leijen.Text.Monadic The document (bool b) shows the literal boolean b using text.
-
dhall Dhall.Marshal.Decode Decode a Bool.
>>> input bool "True" True
-
bv-sized Data.BitVector.Sized -
postgresql-binary PostgreSQL.Binary.Decoding No documentation available.
-
postgresql-binary PostgreSQL.Binary.Encoding No documentation available.
-
attoparsec-data Attoparsec.Data Accepts any string interpretable as a boolean: "1" or "0", "true" or "false", "yes" or "no", "y" or "n", "t" or "f". Case-insensitive.
bool :: f c -> (a -> Bool) -> (a -> c) -> (a -> c) -> Colonnade f a ccolonnade Colonnade No documentation available.