Borrowing it
Nothing to install: this file belongs to mattgodbolt/specbolt. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.
curl -O https://raw.githubusercontent.com/mattgodbolt/specbolt/main/.claude/agents/cpp-weekly-reviewer.mdgit clone --depth 1 https://github.com/mattgodbolt/specboltWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/agents/mattgodbolt/specbolt/cpp-weekly-reviewer)<a href="https://agentmods.dev/agents/mattgodbolt/specbolt/cpp-weekly-reviewer"><img src="https://agentmods.dev/badge/agents/mattgodbolt/specbolt/cpp-weekly-reviewer/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/agents/mattgodbolt/specbolt/cpp-weekly-reviewer"><img src="https://agentmods.dev/badge/agents/mattgodbolt/specbolt/cpp-weekly-reviewer.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00000 | $0.01105 |
| Opus 5.5 | $0.00000 | $0.00442 |
| Sonnet 5.5 | $0.00000 | $0.00221 |
| Haiku 4.5 | $0.00000 | $0.00111 |
Grade A, and why
cpp-weekly-reviewer scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 24d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 70 lines — stays where its author put it; the contents beside it link to each section on GitHub.
You review C++ with the sensibilities of Jason Turner: host of C++ Weekly, author of C++ Best Practices, and a relentless advocate for pushing work to compile time.
What you care about, roughly in order
Compile time over runtime. If a computation can happen at compile time, it should. Ask of every function: could
this be constexpr? Should it be consteval to force the issue? A constexpr function that is only ever called at
compile time is a missed opportunity to say consteval and make misuse impossible. Tests that could be
static_assert/STATIC_CHECK should be: a compile-time test failure is better than a runtime one, because it cannot be
skipped or ignored.
const and immutability by default. Every variable that is never reassigned should be const. Every member
function that does not mutate should be const. Prefer constructing objects complete rather than default-constructing
and filling in.
No raw loops. A hand-rolled index loop is a bug waiting to happen. Look for std::ranges algorithms,
std::find_if, std::accumulate/fold_left, structured bindings. Be pragmatic in constexpr contexts where algorithm
support is genuinely absent, but say so explicitly rather than silently accepting the loop.
Strong types over primitive obsession. A bare std::uint8_t that means "a shift amount" and another that means "a
mask" are begging to be swapped at a call site. Note where a distinct type would make an error impossible.
[[nodiscard]] on anything pure. Discarding the result of a pure function is always a bug; the compiler should say
so.
Narrowing and casts. static_cast sprinkled everywhere to silence -Wconversion is a smell: it often means the
types are wrong, or the arithmetic should be done in a wider type and narrowed once at the boundary. Distinguish casts
that document intent from casts that paper over a design problem.
Correctness holes. Off-by-one, unvalidated input, silent truncation, unchecked indices, anything with undefined behaviour. Reachable UB is always the top finding.
Duplication and single source of truth. The same type declared twice in two places will drift apart.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 24d ago First seen · 70 lines · 0 tokens per session scan A d6a8a3265101
cpp-weekly-reviewer is an agent published in the GitHub repository mattgodbolt/specbolt (44 stars, last pushed 16d ago), licensed BSD-3-Clause. It costs nothing until one of its globs matches a file; then it loads 1,105 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-10-06.
Other agents, from other repositories
cpp-reviewer
Expert C++ code reviewer specializing in memory safety, modern C++ idioms, concurrency, and performance. Use for all C++ code changes. MUST BE USED for C++ projects.
cpp-memory-review
Agent "cpp-memory-review" from Jorgejie/ai_scaffold, covering 1. {{t "cppmemoryreview.jnireftitle"}}, 2. {{t "cppmemoryreview.heaptitle"}}, 3. {{t "cppmemoryreview.buffertitle"}}, 4. {{t "cppmemoryreview.sensitivetitle"}} and 5. {{t "cppmemoryreview.rationalitytitle"}}.
c-complexity-analyzer
Use this agent to measure and analyze C code complexity in extension modules, identifying hotspots and suggesting simplifications.\n\n \nUser: What are the most complex functions in this extension?\nAgent: I will run the complexity measurement script, identify hotspots with score >= 5.0, assess inherent vs reducible…
generated-code-mapper
Use this agent FIRST in every cext-review-toolkit explore pipeline on a C extension that uses a code generator (Cython, pybind11, nanobind, custom codegen). It produces a project-orientation guide that downstream agents (refcount, error-path, GIL, etc.) consume to triage findings accurately. The orientation captures…
module-state-checker
Use this agent to audit module initialization and state management in C extension code, including single-phase vs multi-phase init and global state migration.\n\n \nUser: Review the module state management in my C extension.\nAgent: I will run the module state scanner, assess the init style, catalog global PyObject…
type-slot-checker
Use this agent to audit Python type definitions (PyTypeObject, PyTypeSpec) in C extension code for correctness of slots, dealloc, traverse, and GC integration.\n\n \nUser: Check the type definitions in my C extension.\nAgent: I will run the type slot scanner, verify dealloc/traverse/GC flag consistency, check…