cpp-guide
Installation
SKILL.md
C/C++ Guide
Applies to: C++20, Systems Programming, Embedded, Game Engines, High-Performance Computing
Core Principles
- RAII Everywhere: Every resource (memory, files, locks, sockets) is owned by an object whose destructor releases it
- Zero Raw Ownership: Never use
new/deletedirectly; use smart pointers and containers for all heap allocation - Value Semantics by Default: Pass and return by value; rely on move semantics and copy elision for performance
- Compile-Time over Run-Time: Use
constexpr,static_assert, concepts, and templates to catch errors at compile time - Warnings Are Errors: Build with
-Wall -Wextra -Wpedantic -Werror; every warning is a latent bug