# Cpp coding standards

> Cpp coding standards is an open-source agent skill for developer tools. Guides an AI agent to write and review C++ code using Core Guidelines practices. It is available on Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, Windsurf and Goose.

- **Kind:** Skill
- **Pricing:** Open source
- **Platforms:** Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, Windsurf, Goose
- **Website:** https://github.com/smartworldarafath/REA_Skill/tree/main/.agents/skills/cpp-coding-standards
- **Repository:** https://github.com/smartworldarafath/rea_skill
- **GitHub stars:** 66
- **License:** MIT
- **Skill name:** cpp-coding-standards
- **Collection:** https://github.com/smartworldarafath/REA_Skill
- **Categories:** [developer tools](https://ai-powered.com/categories/developer-tools)
- **Listing updated:** 2026-12-01

## About

This skill gives the agent a reference of C++ Core Guidelines rules covering interfaces, functions, classes, resource management, expressions, error handling, concurrency, templates, naming and performance. It is aimed at C++17, C++20 and C++23 code and is meant to steer new code, reviews and refactors toward modern, type-safe and resource-safe patterns.

The guidance is organized as rule tables and short code examples marked as do and don't, with a closing checklist the agent can run through before calling C++ work finished. It also flags when the standards should be adapted, such as legacy C codebases or embedded targets with hardware constraints.

The skill is instructional only: it contains no scripts or tool calls, so it works by shaping how the agent reads and writes C++ code. It needs a C++ project and a compiler toolchain for the agent to build and test its changes.

## When your agent uses it

> C++ coding standards based on the C++ Core Guidelines (isocpp.github.io). Use when writing, reviewing, or refactoring C++ code to enforce modern, safe, and idiomatic practices.

## What it can access

From a static check of the files on GitHub; nothing was run.

- [Instructions only, no scripts](https://github.com/smartworldarafath/REA_Skill/tree/HEAD/.agents/skills/cpp-coding-standards)
- [License: MIT](https://github.com/smartworldarafath/REA_Skill/tree/HEAD/.agents/skills/cpp-coding-standards)

## Features

- **Interface and type design:** Rules for explicit, strongly typed interfaces, clear ownership and passing parameters by value or const reference.
- **Resource management guidance:** RAII patterns, smart pointer selection and avoiding raw new, delete, malloc and free.
- **Class and hierarchy rules:** Rule of Zero and Rule of Five, virtual destructors, explicit constructors and override usage.
- **Error handling conventions:** Custom exception types thrown by value and caught by reference, with noexcept guidance.
- **Concurrency safety patterns:** Named RAII locks, scoped_lock for multiple mutexes and condition-based waiting.
- **Naming and header hygiene:** Include guards, self-contained headers, namespace rules and underscore-style naming.

## Good for

- Review a C++ pull request for raw pointer ownership and missing RAII
- Refactor legacy C++ functions to use const, constexpr and smart pointers
- Write a new C++ class with a safe copy and move implementation
- Check a header for include guard and using-namespace problems
- Replace C-style casts and plain enums with safer alternatives

## Install

### Claude Code

This skill ships in the `rea-skills` plugin. In Claude Code, add the marketplace and install the plugin (it may include other skills too):

```sh
/plugin marketplace add smartworldarafath/REA_Skill
/plugin install rea-skills@smartworldarafath
```

Or copy only this skill to `~/.claude/skills/cpp-coding-standards`:

```sh
tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/smartworldarafath/REA_Skill.git "$tmp" &&
mkdir -p ~/.claude/skills &&
rm -rf ~/.claude/skills/cpp-coding-standards &&
cp -R "$tmp/.agents/skills/cpp-coding-standards" ~/.claude/skills/cpp-coding-standards &&
rm -rf "$tmp"
```

For one project only, put the folder in `.claude/skills/cpp-coding-standards` inside it instead.

### Codex

Copy the skill folder to `~/.agents/skills/cpp-coding-standards` to use it in every repository:

```sh
tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/smartworldarafath/REA_Skill.git "$tmp" &&
mkdir -p ~/.agents/skills &&
rm -rf ~/.agents/skills/cpp-coding-standards &&
cp -R "$tmp/.agents/skills/cpp-coding-standards" ~/.agents/skills/cpp-coding-standards &&
rm -rf "$tmp"
```

For one repository only, put the folder in `.agents/skills/cpp-coding-standards` inside it instead.

### Cursor

Copy the skill folder to `~/.cursor/skills/cpp-coding-standards` to use it in every project:

```sh
tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/smartworldarafath/REA_Skill.git "$tmp" &&
mkdir -p ~/.cursor/skills &&
rm -rf ~/.cursor/skills/cpp-coding-standards &&
cp -R "$tmp/.agents/skills/cpp-coding-standards" ~/.cursor/skills/cpp-coding-standards &&
rm -rf "$tmp"
```

For one project only, put the folder in `.cursor/skills/cpp-coding-standards` inside it instead.

### Gemini CLI

Run in a terminal (add `--scope workspace` to install it for the current workspace only):

```sh
gemini skills install https://github.com/smartworldarafath/REA_Skill.git --path .agents/skills/cpp-coding-standards
```

Or copy the folder to `~/.gemini/skills/cpp-coding-standards` yourself.

### VS Code

For GitHub Copilot in VS Code, copy the skill folder to `~/.copilot/skills/cpp-coding-standards`:

```sh
tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/smartworldarafath/REA_Skill.git "$tmp" &&
mkdir -p ~/.copilot/skills &&
rm -rf ~/.copilot/skills/cpp-coding-standards &&
cp -R "$tmp/.agents/skills/cpp-coding-standards" ~/.copilot/skills/cpp-coding-standards &&
rm -rf "$tmp"
```

For one project only, put the folder in `.github/skills/cpp-coding-standards` inside it instead.

### Other agents

Get the folder:

```sh
git clone --depth 1 https://github.com/smartworldarafath/REA_Skill.git
```

Then copy `REA_Skill/.agents/skills/cpp-coding-standards` into your agent's skills folder as `cpp-coding-standards`. Agents that support SKILL.md read one folder per skill.

## FAQ

### Which C++ versions does the skill target?

It covers modern C++ from C++17 through C++20 and C++23, and notes that some examples use C++20 features such as concepts.

### Does the skill run any scripts or tools?

No. The skill ships no scripts and only provides guidance and code examples for the agent to follow.

### When should the guidance be skipped?

The skill says not to use it for non-C++ projects or legacy C codebases that cannot adopt modern C++, and to adapt it selectively in embedded or bare-metal contexts.

### What triggers the skill?

It is meant to load when the agent is writing, reviewing or refactoring C++ code to enforce modern and idiomatic practices.

### How do I install Cpp coding standards in Claude Code?

Copy the skill folder from GitHub to ~/.claude/skills/cpp-coding-standards to use it in all your projects, or to .claude/skills/cpp-coding-standards in one project. Or install the rea-skills plugin, which includes it: /plugin marketplace add smartworldarafath/REA_Skill, then /plugin install rea-skills@smartworldarafath.

### Does Cpp coding standards run scripts?

No. It is instructions only, with no scripts. This comes from a static check of the files on GitHub; nothing was run. Read the files before you install it.

### Which AI agents can use Cpp coding standards?

Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, Windsurf and Goose. Each reads skills in the SKILL.md format from its own folder; the install steps on this page list them.

### What are the best alternatives to Cpp coding standards?

The closest alternatives to Cpp coding standards are Readable cpp, Coding standards, Modern cpp, Readable code and Cpp.

## Where this comes from

- Description: from the skill's own SKILL.md.

## Alternatives

- [Readable cpp](https://ai-powered.com/skills/readable-cpp): Readable cpp is an open-source agent skill for developer tools.
- [Coding standards](https://ai-powered.com/skills/coding-standards-smartworldarafath): Coding standards is an open-source agent skill for developer tools.
- [Modern cpp](https://ai-powered.com/skills/modern-cpp): Modern cpp is an open-source agent skill for developer tools.
- [Readable code](https://ai-powered.com/skills/readable-code): Readable code is an open-source agent skill for developer tools.
- [Cpp](https://ai-powered.com/skills/cpp): Cpp is an open-source agent skill for developer tools.
- [Patterns](https://ai-powered.com/skills/patterns-xiaolai): Patterns is an open-source agent skill for developer tools.
- [Rules](https://ai-powered.com/skills/rules-xiaolai): Rules is an open-source agent skill for developer tools.
- [Cpp testing](https://ai-powered.com/skills/cpp-testing): Cpp testing is an open-source agent skill for developer tools.

---
Source: https://ai-powered.com/skills/cpp-coding-standards
