bool, true, false, __bool_true_false_are_defined
Nach oben zu Stdbool.h - Index
Header-Datei
stdbool.h
Kategorie
Variablentypen
Prototyp
bool true = 1;
bool false = 0;
bool h = __bool_true_false_are_defined;
Beschreibung
In der Header-Datei stdbool.h sind vier Makros definiert, die die booleschen Typen genau festlegen.
Beispiel
#include <stdio.h>
#include <stdbool.h>
int main(int , char**){
bool t = true;
bool f = false;
bool h = __bool_true_false_are_defined;
if (h) printf("foo");
return 0;
}
POSIX | Win32 | ANSI C | ANSI C++ |
---|---|---|---|
+ |
+ |
+ |
+ |