https://github.com/murphsicles/smallvec
Inline small vectors for Zeta
https://github.com/murphsicles/smallvec
Last synced: 22 days ago
JSON representation
Inline small vectors for Zeta
- Host: GitHub
- URL: https://github.com/murphsicles/smallvec
- Owner: murphsicles
- License: other
- Created: 2026-05-15T20:06:01.000Z (3 months ago)
- Default Branch: main
- Last Pushed: 2026-05-15T23:13:15.000Z (2 months ago)
- Last Synced: 2026-05-16T00:11:10.291Z (2 months ago)
- Homepage:
- Size: 15.6 KB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# @collections/smallvec — Inline Small Vectors for Zeta
Auto-converted from [smallvec](https://crates.io/crates/smallvec) v2.0.0-alpha.12 via [Dark Factory](https://github.com/murphsicles/dark-factory).
## Features
- **Stack allocation** — stores up to N elements inline, zero heap allocations for small sizes
- **Automatic spilling** — transparently moves to heap allocation when capacity exceeded
- **Full Vec API** — push, pop, insert, remove, extend, resize, retain, dedup, drain, splice
- **IntoIter, Drain, Splice, ExtractIf** — iterator adapters matching standard Vec
- **Union/Intersection** — set-like operations on sorted smallvecs
## Usage
```zeta
use @collections/smallvec::SmallVec;
let mut v: SmallVec<[i64; 4]> = SmallVec::new();
v.push(1); v.push(2); v.push(3); v.push(4); // stays on stack
v.push(5); // spills to heap
```
## Stats: 2 source files, ~2,322 lines, 0 unsupported items
## License
MIT