|
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Contract-violation information | ||||
(C++26) | ||||
(C++26) | ||||
(C++26) | ||||
detection_mode (C++26) | ||||
| Helper functions | ||||
Defined in header <contracts> | ||
enumclass detection_mode:/* unspecified */{ predicate_false=1, | (since C++26) | |
The enumerators ofstd::contracts::detection_mode correspond to the reasons that cause the contract violation to happen under a context that is notmanifestly constant-evaluated, with meanings listed below:
| Enumerator | Meaning |
predicate_false | the contract violation occurs because the result of the predicate isfalse |
evaluation_exception | the contract violation occurs because the evaluation of the predicate exits via an exception |
If a contract violation occurs in a context that is manifestly constant-evaluated, thecontract-violation handler is not invoked.
(C++26) | the type holding the contract-violation information (class)[edit] |
(C++26) | the kind of the contract assertion violated (enum)[edit] |
(C++26) | the evaluation semantic when the contract violation occurs (enum)[edit] |