From 0f578158c1745bd98f940c2124c3463055a400b6 Mon Sep 17 00:00:00 2001 From: David Waern Date: Tue, 9 Oct 2007 16:14:05 +0000 Subject: Add a simple test suite --- tests/pre-2.0-tests/Hash.html.ref | 451 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 451 insertions(+) create mode 100644 tests/pre-2.0-tests/Hash.html.ref (limited to 'tests/pre-2.0-tests/Hash.html.ref') diff --git a/tests/pre-2.0-tests/Hash.html.ref b/tests/pre-2.0-tests/Hash.html.ref new file mode 100644 index 00000000..0e2b6d20 --- /dev/null +++ b/tests/pre-2.0-tests/Hash.html.ref @@ -0,0 +1,451 @@ + + +Hash
 ContentsIndex
Hash
Contents
The HashTable type +
Operations on HashTables +
The Hash class +
Description
Implementation of fixed-size hash tables, with a type + class for constructing hash values for structured types. +
Synopsis
data HashTable key val
new :: (Eq key, Hash key) => Int -> IO (HashTable key val)
insert :: (Eq key, Hash key) => key -> val -> IO ()
lookup :: Hash key => key -> IO (Maybe val)
class Hash a where
hash :: a -> Int
The HashTable type +
data HashTable key val
A hash table with keys of type key and values of type val. + The type key should be an instance of Eq. +
Operations on HashTables +
new :: (Eq key, Hash key) => Int -> IO (HashTable key val)
Builds a new hash table with a given size +
insert :: (Eq key, Hash key) => key -> val -> IO ()
Inserts a new element into the hash table +
lookup :: Hash key => key -> IO (Maybe val)
Looks up a key in the hash table, returns Just val if the key + was found, or Nothing otherwise. +
The Hash class +
class Hash a where
A class of types which can be hashed. +
Methods
hash :: a -> Int
hashes the value of type a into an Int +
show/hide Instances
Hash Float
Hash Int
(Hash a, Hash b) => Hash ((,) a b)
Produced by Haddock version 2.0
-- cgit v1.2.3