Releases: DavidLeeds/hashmap
Releases · DavidLeeds/hashmap
v2.0.3
Hashmap v2.0.2
Minor project updates:
- Fixed a typo in the
hashmap_collisions()
macro. - Moved example into a dedicated directory and added a new CMake option:
HASHMAP_BUILD_EXAMPLES
. - Now including examples in CI build.
- Quoted internal header includes to facilitate embedding the source into another build.
- Updated the readme to include tutorial style examples.
Hashmap v2.0.1
Maintenance release for v2.0.
- Fixed build with Clang compiler. Removed struct definition in
for
loop in thehashmap_foreach
macros. - Defined
HASHMAP_BUILD_TESTS
CMake option and set to OFF, by default CMAKE_BUILD_TYPE
is now Release, by default- Updated README
Hashmap v2.0
Hashmap 2.0 Highlights:
- New generic and type-safe API. We no longer need to use a macro to generate type-safe wrapper functions.
- Improved linear probing algorithm. The previous algorithm could fail on insert, rehash, or remove if a particularly poor hash function was provided. The new algorithm can never fail, even with a worst-case hash function. This adds user confidence and reduces failure modes.
- Added a supplemental hash function. Linear probing is especially sensitive to clustering due to poor hash functions. Since the hash function is user-supplied, adding a supplemental hash function provides more consistent performance.
- Now, always provide hashmap statistics API with no additional overhead to ordinary hashmap operations.
- Now, do lazy allocation on init. We reserve no memory on the heap until the first item is added.
- Default hashmap size is reduced to 128 elements.
- A hashmap_reserve() function was added to pre-allocate the hashmap.
- hashmap_foreach macros have been added to hide the complexities of iterator usage and streamline iteration.
Hashmap v1.0.1
Maintenance release for v1.0. This primarily consists of CMake improvements. This is the last planned code change to v1.
Version 2.0 will include incremental improvements to the core algorithm and a templated API.
Hashmap v1.0
This is the stable version of the hashmap data structure that uses a generic (void *) API with macros to declare type-specific wrapper functions.
Version 2.0 will include the same core algorithm, but a templated API.