| 1 |
/* { dg-options "-std=c99" } */ |
| 2 |
/* Missing <stdbool.h>. */ |
| 3 |
|
| 4 |
bool b; /* { dg-error "unknown type name 'bool'" } */ |
| 5 |
/* { dg-message "'bool' is defined in header '<stdbool.h>'; this is probably fixable by adding '#include <stdbool.h>'" "" { target *-*-* } .-1 } */ |
| 6 |
|
| 7 |
int test_true (void) |
| 8 |
{ |
| 9 |
return true; /* { dg-error "'true' undeclared" } */ |
| 10 |
/* { dg-message "'true' is defined in header '<stdbool.h>'; this is probably fixable by adding '#include <stdbool.h>'" "" { target *-*-* } .-1 } */ |
| 11 |
} |
| 12 |
|
| 13 |
int test_false (void) |
| 14 |
{ |
| 15 |
return false; /* { dg-error "'false' undeclared" } */ |
| 16 |
/* { dg-message "'false' is defined in header '<stdbool.h>'; this is probably fixable by adding '#include <stdbool.h>'" "" { target *-*-* } .-1 } */ |
| 17 |
} |