D++ (DPP)
C++ Discord API Bot Library
Using Coroutines

Warning
D++ Coroutines are a very new feature and are currently only supported by D++ on g++ 11, clang/LLVM 14, and MSVC 19.37 or above. Additionally, D++ must be built with the CMake option DPP_CORO, and your program must both define the macro DPP_CORO and use C++20 or above. The feature is experimental and may have bugs or even crashes, please report any to GitHub Issues or to our Discord Server.

One of the most anticipated features of C++20 is the addition of coroutines: in short, they are functions that can be paused while waiting for data and resumed when that data is ready. They make asynchronous programs much easier to write, but they do come with additional dangers and subtleties.

Coroutines are currently disabled by default; to use them you will need to build D++ from source and use the option -DDPP_CORO=on in your CMake command. Your application also needs to enable C++20 and define DPP_CORO, by using:

  • -std=c++20 -DDPP_CORO in your build command if building manually, or
  • if using CMake, add target_compile_definitions(my_program PUBLIC DPP_CORO) and target_compile_features(my_program PUBLIC cxx_std_20).
D++ Library version 9.0.13D++ Library version 9.0.12D++ Library version 9.0.11D++ Library version 9.0.10D++ Library version 9.0.9D++ Library version 9.0.8D++ Library version 9.0.7D++ Library version 9.0.6D++ Library version 9.0.5D++ Library version 9.0.4D++ Library version 9.0.3D++ Library version 9.0.2D++ Library version 9.0.1D++ Library version 9.0.0D++ Library version 1.0.2D++ Library version 1.0.1D++ Library version 1.0.0