February 10, 20251 yr In this article, we briefly explain everything you need to know to get started with Contracts as proposed for C++26 in P2900. Contracts for C++ explained in 5 minutes by Timur Doumler From the article: With P2900, we propose to add contract assertions to the C++ language. This proposal is in the final stages of wording review before being included in the draft Standard for C++26. It has been suggested by some members of the C++ standard committee that this feature is too large, too complicated, and hard to teach. As it turns out, the opposite is true: contract assertions are actually very simple and can be explained in just five minutes. In this blog post, we will do exactly this! View the full article
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.