this post was submitted on 16 Nov 2024
1 points (100.0% liked)

C & C++

965 readers
15 users here now

founded 5 years ago
MODERATORS
 

In this paper, we propose a Contracts facility for C++ that has been carefully considered by SG21 with a high bar set for level of consensus. The proposal includes syntax for specifying three kinds of contract assertions: precondition assertions, postcondition assertions, and assertion statements. In addition, we specify four evaluation semantics for these assertions โ€” one non- checking semantic, ignore, and three checking semantics, observe, enforce, and quick_enforce โ€” as well as the ability to specify a user-defined handler for contract violations. The features proposed in this paper allow C++ users to leverage contract assertions in their ecosystems in numerous ways.

no comments (yet)
sorted by: hot top controversial new old
there doesn't seem to be anything here