Standard library header <cstdbool> (C++11)(until C++20), <stdbool.h> (C++11)
This header was originally in the C standard library as <stdbool.h>.
Compatibility header. true, false and bool are keywords in C++, but they were not keywords in C until C23.
| C compatibility macro constant, expands to integer literal 1 |
<cstdbool> is deprecated in C++17 and removed in C++20. Corresponding
<stdbool.h> is still available in C++20.
 Defect reports
The following behavior-changing defect reports were applied retroactively to previously published C++ standards.
|DR||Applied to||Behavior as published||Correct behavior|
|LWG 3827||C++11||C programs no longer need the compatibility macro
macro in C++