$ show frankmcsherry/columnar
columnar is a Rust library for columnar representation of Rust data types. It provides a `Columnar` trait and a derive macro that transform ordinary structs and enums into columnar storage: each field is stored in its own typed vector, and enums store tags and payloads separately. The crate supports recursive/tree-structured enums, all-unit enums, `no_std` environments, and optional serde serialization. It is a library, not an application, with no web or CLI surface; the primary entry points are the derive macro and the `Columnar`/`ColumnarVec` traits.
The LLM identified 3 files worth highlighting for reuse:
Procedural macro that derives `Columnar` implementations for structs and enums. It handles recursive enums, all-unit enums, and generates fully scoped paths for `no_std` compatibility. This is a self-contained proc-macro crate that can be extracted and reused as a template for columnar code generation.
Dependency-free module implementing columnar layouts for primitive types and combinators. It deliberately imports nothing from the rest of the crate, making it an isolated, extractable layer for low-level columnar encoding, including offset tables, tag handling, and non-panicking validation paths.
Core traits (`Columnar`, `ColumnarVec`, `ColumnarValue`) and container combinators that define the columnar abstraction. The trait design uses associated types and push/pop operations to separate logical values from their columnar storage, and is the foundation of the crate's reusable API.