C++11 buffer library following Boost C++ Libraries conventions. Snake_case naming, 4-space indentation, RAII patterns, Javadoc-style documentation, and platform-aware symbol visibility.
A skill for developing the Boost.Buffers library (Asio Buffers without the Asio) following Boost C++ Libraries coding standards and conventions.
This skill enables AI agents to write C++11 code for the cppalliance/buffers project following strict Boost conventions: snake_case naming, 4-space indentation, braces-on-own-line, RAII cleanup patterns, comprehensive Javadoc documentation, and platform-aware symbol visibility for cross-platform DLL safety.
1. **Language Standard**: Use C++11 unless otherwise specified
2. **Naming Convention**: Follow Boost C++ Libraries snake_case for all identifiers
3. **Indentation**: 4 spaces, no tabs
4. **Braces**: Place opening braces on their own line for classes and functions
5. **Namespaces**: Never expose symbols from the `detail` namespace publicly
6. **Project Structure**:
- Public headers in `include/`
- Library cpp files and private headers in `src/`
- Test files in `test/`
7. **Error Handling**: Prefer RAII rollback guards over try-catch blocks for cleanup
8. **ABI Compatibility**: No ABI compatibility guarantee across different Boost versions
Follow Boost C++ Libraries Javadoc style strictly:
- Variadic args (`Args...`) — omit
- Types deduced from function parameters — omit (self-evident from `@param`)
**Example 1** (no `@tparam` needed):
```cpp
/** Return the size of the buffer sequence.
@param buffers The buffer sequence to measure.
@return The total byte count.
*/
template<class BufferSequence>
std::size_t
buffer_size(BufferSequence const& buffers);
```
**Example 2** (`@tparam` required):
```cpp
/** Return the default value.
@tparam T The value type.
*/
template<class T>
T default_value();
```
Understand platform behavior:
**vtable requirements**:
**Strategy by class type**:
**Common pitfalls**:
Use this skill when:
Leave a review
No reviews yet. Be the first to review this skill!
# Download SKILL.md from killerskills.ai/api/skills/boostbuffers-c11-development/raw