Copyright | (c) 2018 Iris Ward |
---|---|
License | BSD3 |
Maintainer | aditu.venyhandottir@gmail.com |
Stability | experimental |
Safe Haskell | Trustworthy |
Language | Haskell2010 |
Type level rational numbers expressed as a ratio between a type-level integer
and a type-level natural. For example
.Neg
3 :% 2
See also: Data.TypeInts
Construction
Type constructor for a rational
Linking type and value level
This class gives the (value-level) rational associated with a type-level rational. There are instances of this class for every combination of a concrete integer and concrete natural.
ratSing
ratVal :: forall proxy r. KnownRat r => proxy r -> Rational Source #
Get the value associated with a type-level rational
This type represents unknown type-level integers.
Since: 0.1.1
someRatVal :: Rational -> SomeRat Source #
Convert a rational into an unknown type-level rational.
Since: 0.1.1