Yet Another TypeSafe and Generic Programming Candidate for C
4 days ago
- #productivity
- #library
- #C-programming
- MisraStdC is a modern C11 library designed to enhance productivity in C programming while maintaining performance.
- The library provides generic containers (Vec, Str, Map), string handling, and formatted I/O inspired by higher-level languages.
- Features include cross-platform compatibility (MSVC, GCC, Clang), type-safe containers, Rust-style formatted I/O, and JSON parsing/serialization.
- Memory safety is ensured through proper initialization and cleanup functions, with runtime checks for object integrity.
- The library supports ownership semantics for data insertion into containers (l-value and r-value insertion).
- Comprehensive examples demonstrate usage of vectors, strings, formatted I/O, JSON handling, and process communication.
- Format specifiers support alignment, width, endianness, numeric bases (hex, binary, octal), and precision for floating-point values.
- Installation requires a C11-compatible compiler and uses Meson/Ninja for building.
- The project is open-source under the Unlicense, allowing free use, modification, and distribution without attribution.