← Back to Skills Marketplace
1384
Downloads
2
Stars
9
Active Installs
2
Versions
Install in OpenClaw
/install cpp
Description
Avoid common C++ mistakes — memory leaks, dangling references, undefined behavior, and ownership confusion.
README (SKILL.md)
Quick Reference
| Topic | File |
|---|---|
| RAII, smart pointers, new/delete | memory.md |
| Raw pointers, references, nullptr | pointers.md |
| Rule of 3/5/0, inheritance, virtual | classes.md |
| Containers, iterators, algorithms | stl.md |
| Templates, SFINAE, concepts | templates.md |
| Threads, mutex, atomics | concurrency.md |
| C++11/14/17/20, move semantics | modern.md |
| Undefined behavior traps | ub.md |
Critical Rules
- Raw
newwithoutdeleteleaks — usestd::unique_ptrorstd::make_unique - Returning reference to local — undefined behavior, object destroyed on return
==for C-strings compares pointers — usestd::stringorstrcmp()- Signed integer overflow is UB — not wrap-around like unsigned
- Virtual destructor required in base class — otherwise derived destructor skipped
std::movedoesn't move — it casts to rvalue, enabling move semantics- Moved-from object valid but unspecified — don't use without reassigning
- Data race on non-atomic is UB — use
std::mutexorstd::atomic vector\x3Cbool>is not a real container — returns proxy, usedeque\x3Cbool>map[key]inserts default if missing — usefind()orcontains()to check- Braced init
{}prevents narrowing —int x{3.5}errors,int x(3.5)truncates - Iterator invalidation on
push_back— vector may relocate, invalidating iterators string_viewdoesn't own data — underlying string must outlive the view
Usage Guidance
This skill is a set of C++ reference notes and appears coherent with that purpose. It doesn't request secrets or install code. The only minor oddity is that it declares g++ as a required binary even though it contains only documentation — that's reasonable but not strictly necessary. If you install it, review any code samples the agent produces before compiling or running them, and avoid granting unrelated credentials or elevated permissions to the agent just because a skill is installed.
Capability Analysis
Type: OpenClaw Skill
Name: cpp
Version: 1.0.1
The OpenClaw AgentSkills bundle contains only documentation files (`.md`) and a metadata file (`_meta.json`). The `SKILL.md` file, which is the primary attack surface for prompt injection, describes C++ programming traps and best practices and legitimately declares a dependency on the `g++` compiler. There is no executable code, no instructions for the agent to perform unauthorized actions, no attempts at data exfiltration, persistence, or any other malicious behavior. All content is purely informational and aligned with the stated purpose of providing C++ knowledge.
Capability Assessment
Purpose & Capability
The skill is a C++ guidance/reference pack and declares g++ as a required binary. Requiring g++ is reasonable for a C++ skill (compilation/testing), but the skill is instruction-only and contains only documentation — it does not actually include compile/run steps. This is a minor mismatch but not concerning.
Instruction Scope
SKILL.md and the included Markdown files are purely reference material about C++ pitfalls (memory, UB, concurrency, STL, templates). There are no instructions to read unrelated files, access environment variables, or transmit data to external endpoints.
Install Mechanism
No install spec or code files — the skill is instruction-only, so nothing is downloaded or executed during install.
Credentials
The skill requests no environment variables, credentials, or config paths. No disproportionate access is requested.
Persistence & Privilege
The skill is not set to always: true and uses default autonomous invocation settings. It does not request persistent system-level changes or other skills' configurations.
How to Use
- Make sure OpenClaw is installed (local or Docker)
- Run the install command in chat:
/install cpp - After installation, invoke the skill by name or use
/cpp - Provide required inputs per the skill's parameter spec and get structured output
Version History
v1.0.1
Initial release
v1.0.0
Initial release
Metadata
Frequently Asked Questions
What is C++?
Avoid common C++ mistakes — memory leaks, dangling references, undefined behavior, and ownership confusion. It is an AI Agent Skill for Claude Code / OpenClaw, with 1384 downloads so far.
How do I install C++?
Run "/install cpp" in the OpenClaw or Claude Code chat to install it in one step — no extra setup required.
Is C++ free?
Yes, C++ is completely free (open-source). You can download, install and use it at no cost.
Which platforms does C++ support?
C++ is cross-platform and runs anywhere OpenClaw / Claude Code is available (linux, darwin, win32).
Who created C++?
It is built and maintained by Iván (@ivangdavila); the current version is v1.0.1.
More Skills