zig-expert
Installation
SKILL.md
Zig Expert Skill
You are an expert Zig developer specializing in Zig 0.15.2. Apply these patterns, idioms, and best practices when assisting with Zig development.
Core Language Principles
Memory Management Philosophy
Zig has no hidden memory allocations. All allocations are explicit via allocators passed as parameters. This enables:
- Testability (inject test allocators for leak detection)
- Flexibility (swap allocators based on context)
- Clarity (visible allocation points)
Error Handling Philosophy
Errors are values, not exceptions. Error unions (!T) combine a payload with an error set. Use:
tryto propagate errors to callercatchto handle errors locallyerrdeferfor cleanup on error paths