    {-# LANGUAGE CPP #-}
    {-# OPTIONS_GHC -Wall #-}

    ----------------------------------------------------------------------
    -- |
    -- Module      :  Data.Boolean.Overload
    -- License     :  BSD3
    --
    -- Author      :  Alex Horsman (aninhumer)
    -- Maintainer  :  conal@conal.net
    -- Stability   :  experimental
    --
    --
    -- Definitions of Prelude function names in terms of their corresponding
    -- Data.Boolean generalised implementation. This can then be used as part
    -- of a partial or complete Prelude replacement.
    --
    -- Also exports ifThenElse for use with RebindableSyntax.
    ----------------------------------------------------------------------

    module Data.Boolean.Overload
      ( module Data.Boolean,
        (&&), (||), not,
        ifThenElse,
        (==), (/=),
        (<), (>), (<=), (>=),
        min, max
      ) where

    import Data.Boolean
    import Prelude hiding
      ( (&&), (||), not,
        (==), (/=),
        (<), (>), (<=), (>=),
        min, max
    #if MIN_VERSION_base(4,8,0)
        , (<*)
    #endif
      )

    infix  4  ==, /=, <, <=, >=, >
    infixr 3 &&
    infixr 2 ||

    (&&) :: Boolean a => a -> a -> a
    && :: forall a. Boolean a => a -> a -> a
    (&&) = a -> a -> a
    forall a. Boolean a => a -> a -> a
    (&&*)

    (||) :: Boolean a => a -> a -> a
    || :: forall a. Boolean a => a -> a -> a
    (||) = a -> a -> a
    forall a. Boolean a => a -> a -> a
    (||*)

    not :: Boolean a => a -> a
    not :: forall a. Boolean a => a -> a
    not = a -> a
    forall a. Boolean a => a -> a
    notB

    -- For use with RebindableSyntax
    ifThenElse :: IfB a => BooleanOf a -> a -> a -> a
    ifThenElse :: forall a. IfB a => BooleanOf a -> a -> a -> a
    ifThenElse = BooleanOf a -> a -> a -> a
    forall bool. (bool ~ BooleanOf a) => bool -> a -> a -> a
    forall a bool. (IfB a, bool ~ BooleanOf a) => bool -> a -> a -> a
    ifB

    (==) :: EqB a => a -> a -> BooleanOf a
    == :: forall a. EqB a => a -> a -> BooleanOf a
    (==) = a -> a -> BooleanOf a
    forall bool. (bool ~ BooleanOf a) => a -> a -> bool
    forall a bool. (EqB a, bool ~ BooleanOf a) => a -> a -> bool
    (==*)
    (/=) :: EqB a => a -> a -> BooleanOf a
    /= :: forall a. EqB a => a -> a -> BooleanOf a
    (/=) = a -> a -> BooleanOf a
    forall bool. (bool ~ BooleanOf a) => a -> a -> bool
    forall a bool. (EqB a, bool ~ BooleanOf a) => a -> a -> bool
    (/=*)

    (<) :: OrdB a => a -> a -> BooleanOf a
    < :: forall a. OrdB a => a -> a -> BooleanOf a
    (<) = a -> a -> BooleanOf a
    forall bool. (bool ~ BooleanOf a) => a -> a -> bool
    forall a bool. (OrdB a, bool ~ BooleanOf a) => a -> a -> bool
    (<*)
    (>) :: OrdB a => a -> a -> BooleanOf a
    > :: forall a. OrdB a => a -> a -> BooleanOf a
    (>) = a -> a -> BooleanOf a
    forall bool. (bool ~ BooleanOf a) => a -> a -> bool
    forall a bool. (OrdB a, bool ~ BooleanOf a) => a -> a -> bool
    (>*)
    (<=) :: OrdB a => a -> a -> BooleanOf a
    <= :: forall a. OrdB a => a -> a -> BooleanOf a
    (<=) = a -> a -> BooleanOf a
    forall bool. (bool ~ BooleanOf a) => a -> a -> bool
    forall a bool. (OrdB a, bool ~ BooleanOf a) => a -> a -> bool
    (<=*)
    (>=) :: OrdB a => a -> a -> BooleanOf a
    >= :: forall a. OrdB a => a -> a -> BooleanOf a
    (>=) = a -> a -> BooleanOf a
    forall bool. (bool ~ BooleanOf a) => a -> a -> bool
    forall a bool. (OrdB a, bool ~ BooleanOf a) => a -> a -> bool
    (>=*)

    min :: (IfB a, OrdB a) => a -> a -> a
    min :: forall a. (IfB a, OrdB a) => a -> a -> a
    min = a -> a -> a
    forall a. (IfB a, OrdB a) => a -> a -> a
    minB
    max :: (IfB a, OrdB a) => a -> a -> a
    max :: forall a. (IfB a, OrdB a) => a -> a -> a
    max = a -> a -> a
    forall a. (IfB a, OrdB a) => a -> a -> a
    maxB