| Safe Haskell | Safe |
|---|---|
| Language | Haskell2010 |
Agda.Utils.Size
Description
Collection size.
For TermSize see Agda.Syntax.Internal.
- class Sized a where
- data SizedThing a = SizedThing {
- theSize :: !Int
- sizedThing :: a
- sizeThing :: Sized a => a -> SizedThing a
Documentation
The size of a collection (i.e., its length).
Should fit into an Int. TODO: change to Int.
Minimal complete definition
Instances
| Sized IntSet Source # | |
| Sized Permutation Source # | |
| Sized TopLevelModuleName Source # | |
| Sized ModuleName Source # | |
| Sized QName Source # | |
| Sized [a] Source # | |
| Sized (IntMap a) Source # | |
| Sized (Seq a) Source # | |
| Sized (Set a) Source # | |
| Sized (HashSet a) Source # | |
| Sized (SizedThing a) Source # | Return the cached size. |
| Sized (Tele a) Source # | The size of a telescope is its length (as a list). |
| Sized a => Sized (Abs a) Source # | |
| Sized (Map k a) Source # | |
| Sized (HashMap k a) Source # | |
data SizedThing a Source #
Thing decorated with its size.
The thing should fit into main memory, thus, the size is an Int.
Constructors
| SizedThing | |
Fields
| |
Instances
| Null a => Null (SizedThing a) Source # | |
| Sized (SizedThing a) Source # | Return the cached size. |
sizeThing :: Sized a => a -> SizedThing a Source #
Cache the size of an object.