Skip to content

Latest commit

 

History

History
57 lines (47 loc) · 1.82 KB

File metadata and controls

57 lines (47 loc) · 1.82 KB

slimvec

crates.io | docs.rs | github

SlimVec is analogous to the Standard Library's Vec collection type, however it has a smaller inline-size; the inline data is a thin pointer like thin-vec.

SlimVec implements as much of the API surface of Vec as possible. Additionally includes optional features for arbitrary, borsh, comparable, serde, & valuable.

  SlimVec<T>            Allocation
+-------------+       +-------------+
| ptr: 0xabcd | ----> | length:   2 |
+-------------+       |-------------|
                      | capacity: 4 |
                      |=============|
                      | 0:        A |
                      |-------------|
                      | 1:        B |
                      |-------------|
                      | 2: <uninit> |
                      |-------------|
                      | 3: <uninit> |
                      +-------------+

Licensing

This library may be licensed under any of the following LICENSE-ZLIB, LICENSE-MIT, or LICENSE-APACHE2 at your option.


Copyright © ickk, 2026