Agda-2.6.4: A dependently typed functional programming language and proof assistant
Safe HaskellSafe-Inferred
LanguageHaskell2010

Agda.Utils.HashTable

Description

Hash tables.

Synopsis

Documentation

data HashTable k v Source #

Hash tables.

empty :: IO (HashTable k v) Source #

An empty hash table.

insert :: (Eq k, Hashable k) => HashTable k v -> k -> v -> IO () Source #

Inserts the key and the corresponding value into the hash table.

lookup :: (Eq k, Hashable k) => HashTable k v -> k -> IO (Maybe v) Source #

Tries to find a value corresponding to the key in the hash table.

toList :: (Eq k, Hashable k) => HashTable k v -> IO [(k, v)] Source #

Converts the hash table to a list.

The order of the elements in the list is unspecified.