nats-0.2: Natural numbers

Portabilityportable
Stabilityprovisional
MaintainerEdward Kmett <ekmett@gmail.com>
Safe HaskellTrustworthy

Numeric.Natural.Internal

Description

This module exposes the potentially unsafe operations that are sometimes needed for efficiency: The Natural data constructor and unsafePred.

Synopsis

Documentation

class Integral n => Whole n whereSource

A refinement of Integral to represent types that do not contain negative numbers.

Methods

toNatural :: n -> NaturalSource

unsafePred :: n -> nSource

natural :: a -> (a -> a) -> Natural -> aSource

Church decoding