general-prelude-0.1.2: Prelude replacement using generalized type classes where possible

Safe HaskellNone

Prelude.General

Description

Prelude replacement, use the NoImplicitPrelude extension before importing this.

Synopsis

Documentation

module Data.Bool

module Data.Eq

module Data.Int

module Data.List

module Data.Maybe

module Data.Ord

module Data.Tuple

module System.IO

module Text.Show

(+) :: Num a => a -> a -> a

(-) :: Num a => a -> a -> a

(*) :: Num a => a -> a -> a

(/) :: Fractional a => a -> a -> a

fractional division

mod :: Integral a => a -> a -> a

integer modulus, satisfying

 (x `div` y)*y + (x `mod` y) == x

seq :: a -> b -> b

Evaluates its first argument to head normal form, and then returns its second argument as the result.

($!) :: (a -> b) -> a -> b

Strict (call-by-value) application, defined in terms of seq.

undefined :: a

A special case of error. It is expected that compilers will recognize this and insert error messages which are more appropriate to the context in which undefined appears.

error :: [Char] -> a

error stops execution and displays an error message.

fromIntegral :: (Integral a, Num b) => a -> b

general coercion from integral types

if'Source

Arguments

:: a

Returned if the bool is True

-> a

Returned if the bool is False

-> Bool 
-> a 

An either/maybe equivalent for Bool, often known as if'

filter :: (Monad m, Monoid (m a), Foldable t) => (a -> Bool) -> t a -> m aSource