cpp-memory-management
CommunityMake C++ memory bugs disappear.
AuthorBinh230199
Version1.0.0
Installs0
System Documentation
What problem does it solve?
This Skill helps prevent leaks, dangling pointers, double deletes, use-after-free bugs, and unsafe heap usage in C++ code that must stay reliable in embedded automotive systems.
Core Features & Use Cases
- Ownership design: Define clear lifetime rules for classes, subsystems, and interfaces using Rule of Zero and Rule of Five practices.
- Smart pointer guidance: Choose between unique_ptr, shared_ptr, and weak_ptr to express ownership correctly and avoid cycles.
- RAII and safety patterns: Wrap file handles, locks, buffers, and other resources so cleanup happens automatically and deterministically.
- Real-time memory control: Reduce or eliminate heap allocation in performance-critical Linux, QNX, and Android NDK paths.
- Debugging and audit support: Detect memory defects with AddressSanitizer and review code against MISRA-oriented memory rules.
- Use case: Review an IVI or HUD module, identify raw pointer misuse, and refactor it into safer, allocation-aware C++.
Quick Start
Ask for a review of a C++ class or module and request ownership, lifetime, RAII, and smart pointer recommendations for embedded automotive memory safety.
Dependency Matrix
Required Modules
None requiredComponents
Standard package💻 Claude Code Installation
Recommended: Let Claude install automatically. Simply copy and paste the text below to Claude Code.
Please help me install this Skill: Name: cpp-memory-management Download link: https://github.com/Binh230199/ai/archive/main.zip#cpp-memory-management Please download this .zip file, extract it, and install it in the .claude/skills/ directory.
Agent Skills Search Helper
Install a tiny helper to your Agent, search and equip skill from 536,000+ vetted skills library on demand.