Avoid "bool" variable name

C23 has a type of that name.
This commit is contained in:
Patrick Georgi
2025-09-19 00:08:50 +02:00
parent 4d41663c58
commit c0ad5170c9
4 changed files with 16 additions and 17 deletions

View File

@@ -591,7 +591,7 @@ assert(int p)
return(p);
}
typedef struct {caddr_t max; int i; boolean_t bool;} Rec;
typedef struct {caddr_t max; int i; boolean_t b;} Rec;
static void
check1(Tree_node *x, caddr_t max, Tree_node *z, Rec *rec, Private *private)
@@ -602,14 +602,14 @@ check1(Tree_node *x, caddr_t max, Tree_node *z, Rec *rec, Private *private)
if (x == z) {
rec->max = max;
rec->i = 0;
rec->bool = B_FALSE;
rec->b = B_FALSE;
return;
}
check1(x->llink, max, z, localp, private);
if (private->status == rb_badtable) return;
max = localp->max;
dl = localp->i;
redchild = localp->bool;
redchild = localp->b;
if (!assert (!(redchild && (x->color == red)))) {
private->status = rb_badtable;
return;
@@ -624,7 +624,7 @@ check1(Tree_node *x, caddr_t max, Tree_node *z, Rec *rec, Private *private)
if (private->status == rb_badtable) return;
max = localp->max;
dr = localp->i;
redchild = localp->bool;
redchild = localp->b;
if (!assert (!(redchild && (x->color == red)))) {
private->status = rb_badtable;
return;
@@ -635,7 +635,7 @@ check1(Tree_node *x, caddr_t max, Tree_node *z, Rec *rec, Private *private)
}
rec->max = max;
rec->i = dl + ((x->color == black) ? 1 : 0);
rec->bool = ((x->color == red) ? B_TRUE : B_FALSE);
rec->b = ((x->color == red) ? B_TRUE : B_FALSE);
}
static void