String Interner Versions Save

A data structure to efficiently intern, cache and restore strings.

v0.15.0

3 months ago

Changed

v0.14.0

2 years ago

Added

  • Added the new BufferBackend string interner backend.
    • This backend focuses on minimum memory consumption and allocations at the costs of decreased symbol resolution performance.
    • Use this when memory consumption is your main concern.
  • Added example of how to use a different string interner backend or symbol.
  • Added library docs comparing all the different string interner backends.

Changed

  • The string_interner crate now uses the Rust 2021 edition.
  • The DefaultBackend now is the StringBackend and no longer the BucketBackend.
  • The generic S symbol parameter of all string interner backends now defaults to the DefaultSymbol.
  • The Backend trait is no longer generic over a symbol S but instead has a Symbol associated type now.
  • The StringInterner no longer has a generic S symbol parameter and now instead uses the Symbol associated type from its used backend B.

Dev. Note

  • The memory_consumption tests now shrink the string interners before querying their memory consumption. This yields more stable numbers than before.
  • The memory_consumption test now also tests the total amount of allocations and deallocations made by the string interner backends.
  • Add README section about benchmarking the crate.

v0.13.0

2 years ago
  • Update hashbrown dependency from version 0.9 to version 0.11.

  • Add shrink_to_fit method to StringInterner via backend. (#36)

  • Add support more than 4G of interned strings with StringBackend. (#37)

  • Remove S: Symbol trait bound from interner backends.

  • Remove S: Symbol trait bound from Clone impl for StringBackend.

  • Reworked the memory and allocation tests

    • Run them via cargo test -- --test-threads 1
  • CI now tests the whole build for windows, linux (ubuntu) and macos.

  • Add cargo-audit and cargo-outdated checks to CI pipeline.

  • Remove no longer needed jemalloc dev-dependency.

v0.12.2

3 years ago
  • Ensure cloned StringInterner can still look up the same symbols. #34 (Thanks @alamb)
    • This requires BuildHasher: Clone trait bound for StringInterner's Clone impl.

v0.12.1

3 years ago
  • The BucketBackend now implements Send + Sync.
  • Implemented some minor internal improvements.
  • Update dependencies:
    • hashbrown 0.8 -> 0.9
    • cfg-if 0.1 -> 1.0