Load when reviewing, refactoring, modernizing, debugging, or designing non-trivial C++ code where ownership, lifetime, RAII, concurrency, templates, interfaces, exceptions, or Core Guidelines compliance may affect correctness, safety, maintainability, or performance.
Review C++ code in this order:
Never mix safety-critical changes with style rewrites.
Before subjective review, discover project tooling:
compile_commands.jsonCMakeLists.txt or build system config.clang-tidy configPrefer tool-backed findings when available. Run clang-tidy before eyeballing code.
Do not mechanically replace raw pointers. Classify first:
Only change ownership types after confirming construction, destruction, transfer, aliasing, and ABI constraints.
Separate changes into:
Do not modernize code before preserving behavior. Do not replace legacy code just because it looks old.
Not all rules apply to all projects.
references/concurrency.mdreferences/error-handling.mdreferences/templates.mdreferences/performance.mdreferences/lifetime.mdreferences/rule-map.mdRead GOTCHAS.md for AI failure patterns in C++.
These come from real model mistakes, not from textbooks.
To use this constitution in a real C++ project, see templates/phase0-starter.md.
It provides a step-by-step guide and copy-paste prompt for starting a new project with AI constitution constraints.
Categorize findings by severity:
Actionable comments only. No style nitpicks without engineering value.
references/.f7ba39e
Also appears in
since Jul 31, 2026
If you maintain this skill, you can claim it as your own. Once claimed, you can manage eval scenarios, bundle related skills, attach documentation or rules, and ensure cross-agent compatibility.