-- Hoogle documentation, generated by Haddock
-- See Hoogle, http://www.haskell.org/hoogle/


-- | (?) and (?>) conditional operator
--   
--   (?) and (?&gt;) conditional operator, it can be used with any existed
--   version of base.
@package if
@version 0.1.0.0


-- | This module provides two simple operators <a>?</a> and <a>?&gt;</a>
--   for simple conditions. Watch out for boolean blindness if you use them
--   too often.
module If

-- | This is the <a>if-then-else</a> operator, With it you can write
--   <tt>xxx ? yyy $ zzz</tt> instead of <tt>if xxx then yyy else zzz</tt>.
--   Following may or may not be cleaner to you ; )
--   
--   <pre>
--   isFoo &lt;- checkFoo
--   isFoo ? foo
--         $ bar
--   </pre>
(?) :: Bool -> a -> a -> a
infixr 1 ?

-- | This is the <a>whenM</a> operator, With it you can write
--   <tt>doesItExists ?&gt; removeIt</tt> instead of <tt>do {e &lt;-
--   doesItExists; when e removeIt}</tt>. There's not <tt>unlessM</tt>
--   version, so you have to use <a>not</a>.
--   
--   <pre>
--   not &lt;$&gt; doesItExists ?&gt; createIt
--   </pre>
(?>) :: Monad m => m Bool -> m () -> m ()
infixl 1 ?>
