siiky
2023/02/09
2023/05/15
2023/05/15
programming
No introductions needed.
Type-safe, type-agnostic data structures in single-header C files through the power of C macrology. Heavily inspired by nothings/stb, swenson/sort, and other similar libraries. Includes a suite of QuickCheck-like tests, using an easy to use C library: theft.
- vec.h: where it all started: dynamic vector -- configurable comparator, destructor, (de)growth factor, ...
- map.h: fast hash-map -- configurable keys&values types, hash, comparator, number of buckets, ...
- bs.h: bitset
- ftr.h: future/delay/lazy-evaluation/w.e.
- tralloc.h: (deps: vec.h) track memory with more memory!
- unused.h: suppress those annoying unused warnings
- ifjmp.h: neat macro to make error handling a bit less of a pain
- ifnotnull.h: tiny macro to conditionally call a function if a certain value isn't NULL
- common.h: the classic min and max macros, of course
- sbn.h: (WIP in the "sbn" branch) (deps: vec.h) a shitty (integer) BigNums implementation (following MCA)
- rc.h: (unfinished, in the "rc" branch) a RefCount library, useful for memory management
Simple tar-like program. Defined its own file format, parser, and unparser. Remember trying radamsa (a fuzzer) to generate star files, and it wasn't as catastrophic as I'd expected! I found a couple of bugs, but otherwise star stood its ground well.
radamsa may have been my first contact with Scheme!