string-hash-interner

Crates.iostring-hash-interner
lib.rsstring-hash-interner
version0.20.0
created_at2025-03-01 16:43:40.832054+00
updated_at2025-03-01 16:49:33.692302+00
descriptionEfficient string interner with minimal memory footprint and fast access to the underlying strings.
homepage
repositoryhttps://github.com/blt-r/string-hash-interner
max_upload_size
id1573861
size92,599
blt__ (blt-r)

documentation

https://docs.rs/string-hash-interner

README

String Hash Interner

A fork of robbepop/string-interner.

The main point of this fork is that the hashes of the strings interned are cached, and can be cheaply looked up with Interner::get_hash and Interner::get_hash_unchecked.

I only implemented this for the "String Backend", as that's the only backend I need. Figuring out how to implement this for other backends or make an interface with ability for backends to support this optionally is too complicated, so other backends were just removed.

This fork also makes the Interner generic over the type of strings interned. String types that are supported are: str, CStr, OsStr, [u8], [char].

Commit count: 422

cargo fmt