Safe Haskell | None |
---|---|

Language | Haskell2010 |

- data Unsigned n

# Documentation

Arbitrary-width unsigned integer represented by `n`

bits

Given `n`

bits, an `Unsigned`

`n`

number has a range of: [0 .. 2^`n`

-1]

**NB**: The `Num`

operators perform `wrap-around`

on overflow. If you want
saturation on overflow, check out the `SaturatingNum`

class.

Resize Unsigned | |

KnownNat n => Bounded (Unsigned n) | |

KnownNat n => Enum (Unsigned n) | The functions: |

Eq (Unsigned n) | |

KnownNat n => Integral (Unsigned n) | |

KnownNat n => Num (Unsigned n) | |

Ord (Unsigned n) | |

KnownNat n => Real (Unsigned n) | |

Show (Unsigned n) | |

KnownNat n => Bits (Unsigned n) | |

KnownNat n => FiniteBits (Unsigned n) | |

KnownNat n => Default (Unsigned n) | |

KnownNat n => Lift (Unsigned n) | |

(KnownNat n, KnownNat ((+) 1 n), KnownNat ((+) n n)) => SaturatingNum (Unsigned n) | |

BitPack (Unsigned n) | |

Bundle (Unsigned n) | |

(KnownNat ((+) 1 (Max m n)), KnownNat ((+) m n)) => ExtendingNum (Unsigned m) (Unsigned n) | |

Typeable (Nat -> *) Unsigned | |

type Unbundled clk (Unsigned n) = CSignal clk (Unsigned n) | |

type BitSize (Unsigned n) = n | |

type AResult (Unsigned m) (Unsigned n) = Unsigned ((+) 1 (Max m n)) | |

type MResult (Unsigned m) (Unsigned n) = Unsigned ((+) m n) |