diff options
| author | Tyge Løvset <[email protected]> | 2021-03-29 14:27:14 +0200 |
|---|---|---|
| committer | Tyge Løvset <[email protected]> | 2021-03-29 14:27:14 +0200 |
| commit | c8a7b59dcc8a1d6cd7bf5f5bc6b76f26a97b34d6 (patch) | |
| tree | d2a3876500a66c5967acb8163b16c20c06e93ae4 /docs/cbits_api.md | |
| parent | 535af062240a244bb8397634ceec985e5a7f30ed (diff) | |
| download | STC-modified-c8a7b59dcc8a1d6cd7bf5f5bc6b76f26a97b34d6.tar.gz STC-modified-c8a7b59dcc8a1d6cd7bf5f5bc6b76f26a97b34d6.zip | |
Another update of cbits.
Diffstat (limited to 'docs/cbits_api.md')
| -rw-r--r-- | docs/cbits_api.md | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/docs/cbits_api.md b/docs/cbits_api.md index 86a91e1b..e4b60da6 100644 --- a/docs/cbits_api.md +++ b/docs/cbits_api.md @@ -19,6 +19,7 @@ All cbits definitions and prototypes are available by including a single header ```c cbits cbits_init(void); cbits cbits_with_size(size_t size, bool value); +cbits cbits_with_values(size_t size, uint64_t pattern); cbits cbits_from_str(const char* str); cbits cbits_clone(cbits other); @@ -35,17 +36,17 @@ size_t cbits_count(cbits set); // count number of bool cbits_test(cbits set, size_t i); bool cbits_at(cbits set, size_t i); // same as cbits_test() -bool cbits_is_subset(cbits set, cbits other); // is set a subset of other? -bool cbits_is_disjoint(cbits set, cbits other); // xor test +bool cbits_subset_of(cbits set, cbits other); // is set a subset of other? +bool cbits_disjoint(cbits set, cbits other); // no common bits char* cbits_to_str(cbits set, char* str, size_t start, intptr_t stop); void cbits_set(cbits *self, size_t i); void cbits_reset(cbits *self, size_t i); -void cbits_set_value(cbits *self, size_t i, bool value); -void cbits_flip(cbits *self, size_t i); void cbits_set_all(cbits *self, bool value); -void cbits_set_all64(cbits *self, uint64_t pattern); +void cbits_set_value(cbits *self, size_t i, bool value); +void cbits_set_values(cbits *self, uint64_t pattern); void cbits_flip_all(cbits *self); +void cbits_flip(cbits *self, size_t i); void cbits_intersect(cbits *self, cbits other); void cbits_union(cbits *self, cbits other); |
