typerep-map-0.3.3.0: Efficient implementation of a dependent map with types as keys

Copyright(c) 2017-2020 Kowainik
LicenseMPL-2.0
MaintainerKowainik <xrom.xkov@gmail.com>
Safe HaskellNone
LanguageHaskell2010

Data.TypeRep.Vector

Contents

Description

TypeRepMap implementation based on Vector.

Synopsis

Documentation

data TF f where Source #

Constructors

TF :: Typeable a => f a -> TF f 

empty :: TypeRepVector f Source #

Empty structure.

insert :: forall a f. a -> TypeRepVector f -> TypeRepVector f Source #

Inserts the value with its type as a key.

lookup :: forall a f. Typeable a => TypeRepVector f -> Maybe (f a) Source #

Looks up the value at the type. >>> let x = lookup $ insert (11 :: Int) empty >>> x :: Maybe Int Just 11 >>> x :: Maybe () Nothing

size :: TypeRepVector f -> Int Source #

Returns the size of the TypeRepVect.

fromList :: forall f. [TF f] -> TypeRepVector f Source #

Orphan instances

Unbox Fingerprint Source # 
Instance details

Vector Vector Fingerprint Source # 
Instance details

MVector MVector Fingerprint Source # 
Instance details