vector-0.10.12.1: Efficient Arrays

Copyright(c) Roman Leshchinskiy 2008-2010
LicenseBSD-style
MaintainerRoman Leshchinskiy <rl@cse.unsw.edu.au>
Stabilityexperimental
Portabilityportable
Safe HaskellSafe-Inferred
LanguageHaskell2010

Data.Vector.Fusion.Stream.Size

Description

Size hints for streams.

Synopsis

Documentation

data Size Source

Size hint

Constructors

Exact Int

Exact size

Max Int

Upper bound on the size

Unknown

Unknown size

Instances

smaller :: Size -> Size -> Size Source

Minimum of two size hints

larger :: Size -> Size -> Size Source

Maximum of two size hints

toMax :: Size -> Size Source

Convert a size hint to an upper bound

upperBound :: Size -> Maybe Int Source

Compute the maximum size from a size hint if possible