Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add skills/juanmarchetto/agent-skills/c-cpp-analyzernpx skills add JuanMarchetto/agent-skills --skill c-cpp-analyzergit clone --depth 1 https://github.com/JuanMarchetto/agent-skillsWrote 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/skills/juanmarchetto/agent-skills/c-cpp-analyzer)<a href="https://agentmods.dev/skills/juanmarchetto/agent-skills/c-cpp-analyzer"><img src="https://agentmods.dev/badge/skills/juanmarchetto/agent-skills/c-cpp-analyzer.svg" alt="Measured on agentmods" 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 | $0.00062 | $0.00939 |
| Opus 5 | $0.00031 | $0.00469 |
| Sonnet 5 | $0.00012 | $0.00188 |
| Haiku 4.5 | $0.00006 | $0.00094 |
Grade A, and why
c-cpp-analyzer 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 4d 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 — 81 lines — stays where its author put it; the contents beside it link to each section on GitHub.
C/C++ Analysis for Migration
Difficulty Classification
Uses tree-sitter AST analysis with regex fallback:
- Easy: Pure functions, simple arithmetic, no pointers, <30 lines
- Medium: Pointer parameters, simple structs, bounded arrays, malloc with clear ownership
- Hard: void*, function pointers, unions, goto, complex lifetimes, macro-heavy, coroutines
Hard signals (any 1 → Hard):
gotostatementsuniontypesvoid*pointers- Function pointer callbacks
- Coroutine patterns (Duff's device,
switch-based state machines) - setjmp/longjmp
Medium signals (1+ with >30 lines → Medium):
- Pointer declarations
- Cast expressions
malloc/callocusage
Pattern Detection
| C Pattern | Rust Equivalent | Difficulty |
|---|---|---|
ptr + len pairs |
&[T] slices |
Medium |
| Error code returns | Result<T, E> |
Easy |
| NULL checks | Option<T> |
Easy |
malloc/free |
Vec<T>, Box<T> |
Medium |
char* strings |
&str, String |
Medium |
| Manual iteration with pointers | .iter(), .enumerate() |
Medium |
goto cleanup |
Drop trait, ? operator |
Hard |
| Global mutable state | Function parameters, OnceLock |
Hard |
| Bit manipulation | Same ops with explicit types | Medium |
union |
enum with variants |
Hard |
| Function pointers / callbacks | Enum dispatch (preferred) or Fn traits |
Hard |
| Linked lists (next/prev) | Vec<T> (flatten) |
Medium |
| Type tag + union (tagged union) | enum with data variants |
Medium-Hard |
| Recursive data structures | enum + Box<T> |
Medium |
| Coroutine via switch/case | Explicit state machine (match loop) |
Hard |
| Printf format strings | format!() / println!() macros |
Easy-Medium |
strdup/strcpy |
.to_string(), .clone() |
Easy |
Size-Based Strategy
| LOC Range | Strategy | Chunking | Repair Iters |
|---|---|---|---|
| <800 | Single-pass translation | No | Full (5) |
| 800-2000 | Chunked (400 LOC target) | Structural (data model first) | Full (8 for chunked) |
| 2000+ | Chunked (500 LOC target) | Structural | Reduced (2) |
| 4000+ | Consider per-module split | split_into_modules() | Reduced (2) |
What ships with it
3 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
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.
- 4d ago First seen · 81 lines · 62 tokens per session scan A 419e40f7248e
c-cpp-analyzer is a skill published in the GitHub repository JuanMarchetto/agent-skills (5 stars, last pushed 5mo ago), licensed MIT. It adds 62 tokens to every session and 939 once invoked, about $0.0003 per session on Opus 5. 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-08-31.
Other skills, from other repositories
x402
Set up Browser Use Cloud payments with x402 — pay per request from a crypto wallet (USDC on Base mainnet), no signup or API key. Two setups it works out up front — "just use it" (set up a wallet so you or Claude Code can run cloud browser tasks paid from the wallet — Claude writes and runs throwaway scripts, nothing…
browser-use
Direct browser control via CDP for web interaction: automation, scraping, testing, screenshots, and site/app work.
remote-browser
Controls an isolated Browser Use Cloud browser from a sandboxed machine with the current Browser Use CLI.
opencli-browser
Use when an agent needs to drive a real Chrome window via opencli — inspect a page, fill forms, click through logged-in flows, or extract data ad-hoc. Covers the selector-first target contract, compound form fields, stale-ref handling, network capture, and the agent-native envelopes the CLI returns. Not for writing…
opencli-adapter-author
Use when writing an OpenCLI adapter for a new site or adding a new command to an existing site. Guides end-to-end from first recon through field decoding, adapter coding, and verify. Replaces opencli-oneshot / opencli-explorer. For ad-hoc browser driving (no adapter), see opencli-browser instead; for a top-level…
cloud
Documentation reference for using Browser Use Cloud — the hosted API and SDK for browser automation. Use this skill whenever the user needs help with the Cloud REST API (v2, v3, or v4), browser-use-sdk (Python or TypeScript), X-Browser-Use-API-Key authentication, cloud sessions, browser profiles, profile sync, CDP…