Mescal
Loading...
Searching...
No Matches
type_boolarray.h
Go to the documentation of this file.
1
6#ifndef BOOLARRAY_H_
7#define BOOLARRAY_H_
8
9 /* ____ _ */
10 /* | __ ) ___ ___ | | ___ __ _ _ __ __ _ _ __ _ __ __ _ _ _ ___ */
11 /* | _ \ / _ \ / _ \| |/ _ \/ _` | '_ \ / _` | '__| '__/ _` | | | / __| */
12 /* | |_) | (_) | (_) | | __/ (_| | | | | | (_| | | | | | (_| | |_| \__ \ */
13 /* |____/ \___/ \___/|_|\___|\__,_|_| |_| \__,_|_| |_| \__,_|\__, |___/ */
14 /* |___/ */
15
16#include "tools.h"
17
18
19
28
29typedef struct {
30 uchar* array;
31 uint size;
33} barray;
34
46);
47
56);
57
63);
64
70 uint
71);
72
78 uint
79);
80
89 uint
90);
91
103 barray*
104);
105
106
114void or_barray_mod(barray*,
115 barray*
116);
117
129 barray*
130);
131
132
141 barray*
142);
143
152);
153
154
155
156#endif
Type used to represent an array of Booleans.
Definition type_boolarray.h:29
uint size
The number of stored Boolean values.
Definition type_boolarray.h:31
uint size_array
The size of the actual array.
Definition type_boolarray.h:32
uchar * array
The array.
Definition type_boolarray.h:30
void or_barray_mod(barray *, barray *)
Bitwise disjunction of two Boolean arrays of the same size. Modifies the first array.
Definition type_boolarray.c:68
barray * create_barray(uint)
Creation of an array of Booleans.
Definition type_boolarray.c:4
void settrue_barray(barray *, uint)
Sets a cell to true in an array of Booleans.
Definition type_boolarray.c:33
barray * or_barray(barray *, barray *)
Bitwise disjunction of two Boolean arrays of the same size.
Definition type_boolarray.c:57
void and_barray_mod(barray *, barray *)
Bitwise conjunction of two Boolean arrays of the same size. Modifies the first array.
Definition type_boolarray.c:87
bool getval_barray(barray *, uint)
Returns the value of a cell in an array of Booleans.
Definition type_boolarray.c:49
void delete_barray(barray *)
Release of an array of Booleans.
Definition type_boolarray.c:26
barray * copy_barray(barray *)
Copy of an array of Booleans.
Definition type_boolarray.c:96
void setfalse_barray(barray *, uint)
Sets a cell to false in an array of Booleans.
Definition type_boolarray.c:41
barray * and_barray(barray *, barray *)
Bitwise conjunction of two Boolean arrays of the same size.
Definition type_boolarray.c:76
uint getsize_barray(barray *)
Computation of the size of an array of Booleans.
Definition type_boolarray.c:22