*(gcrypt.info)* Bit manipulations

Info Catalog
*(gcrypt.info)* **Comparisons**
*(gcrypt.info)* **MPI library**
*(gcrypt.info)* **Misc**
Bit manipulations
=================
There are a couple of functions to get information on arbitrary bits in
an MPI and to set or clear them:
*- Function: unsigned int gcry_mpi_get_nbits (gcry_mpi_t A)*
Return the number of bits required to represent A.
*- Function: int gcry_mpi_test_bit (gcry_mpi_t A, unsigned int N)*
Return true if bit number N (counting from 0) is set in A.
*- Function: void gcry_mpi_set_bit (gcry_mpi_t A, unsigned int N)*
Set bit number N in A.
*- Function: void gcry_mpi_clear_bit (gcry_mpi_t A, unsigned int N)*
Clear bit number N in A.
*- Function: void gcry_mpi_set_highbit (gcry_mpi_t A, unsigned int N)*
Set bit number N in A and clear all bits greater than N.
*- Function: void gcry_mpi_clear_highbit (gcry_mpi_t A, unsigned int N)*
Clear bit number N in A and all bits greater than N.
*- Function: void gcry_mpi_rshift (gcry_mpi_t X, gcry_mpi_t A,*
unsigned int N)
Shift the value of A by N bits to the right and store the result
in X.

Info Catalog
*(gcrypt.info)* **Comparisons**
*(gcrypt.info)* **MPI library**
*(gcrypt.info)* **Misc**

*automatically generated by *
**info2html**