◐ Shell
clean mode source ↗

Contract support (C++26) - cppreference.com

From cppreference.com

The contract support library defines several types for reporting information about contract violations.

Contract-violation information

Defined in header <contracts>

Defined in namespace std::contracts

the type holding the contract-violation information
(class) [edit]
the kind of the contract assertion violated
(enum) [edit]
the evaluation semantic when the contract violation occurs
(enum) [edit]
the reason that causes the contract violation
(enum) [edit]

Helper functions

Notes

Feature-test macro Value Std Feature
__cpp_lib_contracts 202502L (C++26) Contract support library