What problem does it solve?
Asio's API changed shape three times (classic io_service, io_context, C++20 coroutines), and most example code online targets the oldest era, so code copied from the internet often fails to compile on the user's actual Boost version. This Skill picks the correct async style from the target toolchain first, then applies version-verified rules for strands, buffers, write queues, and framing.
Core Features & Use Cases
- Toolchain-first style selection: Maps Boost version and C++ standard to the correct style — C++20 coroutines, pre-C++20 completion handlers, stackful asio::spawn, or classic io_service — with compile-verified version floors from Boost 1.62 through 1.90.
- Correctness rules for the hard parts: Enforces per-connection strands plus an outbound write queue (a strand alone does not prevent interleaved writes), buffer lifetime management, enable_shared_from_this capture, and composed async_read framing.
- SSL/TLS and build configuration: Provides CMake setups for Boost.Asio, standalone Asio, and dual-mode builds, including -fcoroutines for GCC and BOOST_ERROR_CODE_HEADER_ONLY placement.
- Use Case: You must add a TCP server to a product that still builds on Debian bookworm (Boost 1.74). The Skill steers you to the callback style with any_io_executor, avoiding coroutine headers that do not exist in that Boost version.
Quick Start
Ask the AI to write a full-duplex TCP server with Boost.Asio targeting your specific Boost version and C++ standard, and have it verify every API against the version floors before compiling.