diff options
| author | Mattias Andrée <maandree@kth.se> | 2016-03-03 12:47:39 +0100 |
|---|---|---|
| committer | Mattias Andrée <maandree@kth.se> | 2016-03-03 12:47:39 +0100 |
| commit | 3728c12ecbe308092b213f1b664303a48858a2b8 (patch) | |
| tree | b4a42c978eb513605ef58092c84ecbecbff795dd /man/zbset.3 | |
| parent | Add zdivmod (diff) | |
| download | libzahl-3728c12ecbe308092b213f1b664303a48858a2b8.tar.gz libzahl-3728c12ecbe308092b213f1b664303a48858a2b8.tar.bz2 libzahl-3728c12ecbe308092b213f1b664303a48858a2b8.tar.xz | |
Add zbset
Signed-off-by: Mattias Andrée <maandree@kth.se>
Diffstat (limited to 'man/zbset.3')
| -rw-r--r-- | man/zbset.3 | 39 |
1 files changed, 39 insertions, 0 deletions
diff --git a/man/zbset.3 b/man/zbset.3 new file mode 100644 index 0000000..afa006f --- /dev/null +++ b/man/zbset.3 @@ -0,0 +1,39 @@ +.TH ZBSET 3 libzahl +.SH NAME +zbset - Set, clear, or flip a bit in a big integer +.SH SYNOPSIS +.nf +#include <zahl.h> + +void zbset(z_t \fIa\fP, z_t \fIb\fP, size_t \fIindex\fP, int \fIset\fP); +.fi +.SH DESCRIPTION +.B zbset +either sets, clears, or flips the bit with the selected +.I index +in +.IR b , +and stores the result in +.IR a . +.P +The bit is set if +.IR "(set>0)" , +clear if +.IR "(set==0)" , +and flipped if +.IR "(set<0)" . +.P +It is safe to call +.B zbset +with non-unique parameters. +.SH SEE ALSO +.BR zbtest (3), +.BR zand (3), +.BR zor (3), +.BR zxor (3), +.BR znot (3), +.BR zlsh (3), +.BR zrsh (3), +.BR zsplit (3), +.BR zlsb (3), +.BR zbits (3) |
