c-cpp-dev

A set of rules for writing and reviewing C and C++ code, especially for 32-bit ARM embedded systems. It covers language settings, headers, memory layout, and implementation structure.

In plain words
What is it for?
Creating or reviewing embedded C/C++ source and headers, designing memory-conscious data structures, and checking code against the project’s compiler and language standard.
Why use it?
It helps avoid common embedded-code problems involving shared declarations, stack use, alignment, compiler settings, and maintainability.

Skill for Claude CodeCodex

Install

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.

agentmods
npx agentmods add skills/amethystluna/embedded-workbench/c-cpp-dev
Any agent
npx skills add AmethystLuna/embedded-workbench --skill c-cpp-dev
Clone the repo
git clone --depth 1 https://github.com/AmethystLuna/embedded-workbench

Made for: Claude Code, Codex.

Per session 61 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,421 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

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.

ModelPer sessionOnce invoked
Fable 5 $0.00061 $0.01421
Opus 5 $0.00030 $0.00711
Sonnet 5 $0.00012 $0.00284
Haiku 4.5 $0.00006 $0.00142

Measured yesterday against content hash 9f29e36d8c3d, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

c-cpp-dev 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 yesterday.

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.

skills/c-cpp-dev/SKILL.md · 122 lines

How it starts

The opening of the file, as written. The whole thing — 122 lines — stays where its author put it; the contents beside it link to each section on GitHub.

C/C++ Development

Language baseline is project-specific: check the project's CLAUDE.md, build system (-std= flags), or compiler configuration. All rules assume 32-bit ARM target unless otherwise noted.

Code Generation

  • Respect the project's configured language standard. Don't assume a default.
  • When a header is shared between C and C++ translation units, never define variables in the header — not even with static. Use extern in the header and exactly one definition in a single .c file.
  • Allow goto when it simplifies cleanup or reduces complexity, but use it as a maintenance tool, not a first choice.
  • Place Doxygen comments in header files. Keep implementation files focused on behavior.
  • Avoid inline functions in header files. Keep function definitions in source files so the interface stays small.
  • In C, lightweight macros or helper wrappers are acceptable if simple, local, and clearly named.

Memory Layout

  • Watch local variable bursts inside functions. Large automatic arrays, structs, or many temporaries are stack budget items.
  • Design structures with both semantics and byte alignment in mind. For protocol parsing, byte streams, and wire formats, make packing and endianness explicit.
  • Use pragma or packing attributes only when they match a wire-format requirement and are documented clearly.
  • Use double precision and 64-bit integers with caution on 32-bit targets. Operations on 64-bit objects create performance, compatibility, and atomicity problems unless the wider width is clearly required.
  • When a 64-bit value crosses a task, interrupt, or module boundary, make its access pattern explicit: copied, split, guarded, or protected from tearing.

Read the full file on GitHub · 122 lines

Changes

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.

  1. yesterday First seen · 122 lines · 61 tokens per session scan A 9f29e36d8c3d

Subscribe to this mod's changes

c-cpp-dev is a skill published in the GitHub repository AmethystLuna/embedded-workbench (5 stars, last pushed yesterday), licensed MIT. It adds 61 tokens to every session and 1,421 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.

Related

Other skills, from other repositories

cordis-plugin-development

Create, modify, debug, or extend dynamic Cordis Plugins, including Host Services and Events, Client Slot and theme UI, Package-private Client-to-Host calls, dynamic Tools, version updates, approval failures, and runtime diagnostics. Use this Skill to route a user request to the correct platform and Inspect Provider…

deepseek-ai/deepseek-harness · 80 tokens

editing-cordis-compositions

Use when creating, changing, or validating a Cordis composition for this harness — writing or editing an agent preset, adding or removing a plugin row, deciding whether something belongs to the host composition or to one session, checking whether a preset you authored actually mounts, or diagnosing a row that mounted…

deepseek-ai/deepseek-harness · 69 tokens

record-browser-gif

Record browser or Web UI interaction demos as optimized GIFs using the available built-in browser, state-based frame capture, and deterministic encoding, then publish to a dedicated assets branch when the task includes attaching the GIF to a pull request. Use when asked to make, record, or generate a GIF that…

deepseek-ai/deepseek-harness · 99 tokens

dsh-merging-stacked-prs

Use when landing a stack of dependent GitHub PRs (A ← B ← C, where each bases on the one below) onto master, merging a PR whose base is another open PR's branch, or whenever a request mentions "stacked PRs", "PR stack", "dependent PRs", or merging several related PRs in sequence. Requires every same-repository…

deepseek-ai/deepseek-harness · 118 tokens

dsh-pre-push-checks

Use before pushing, force-pushing, marking ready for review, or claiming checks pass on a deepseek-harness branch, and immediately after gh stack sync publishes rewritten branches, to select the smallest tests and checks that cover the outgoing or just-published diff without reflexively running the full repository…

deepseek-ai/deepseek-harness · 68 tokens

dsh-doc

Create, restructure, review, audit, or migrate DeepSeek Harness Markdown documentation, package READMEs, and the documentation website using audience-first hierarchy, kind-mapped YAML metadata, bilingual line alignment, summary/contents navigation, progressive user-to-developer detail, executed-operation…

deepseek-ai/deepseek-harness · 95 tokens