Teuchos Package Browser (Single Doxygen Collection)
Version of the Day
|
Arbitrary-precision unsigned integer class. More...
#include <Teuchos_BigUIntDecl.hpp>
Public Member Functions | |
BigUInt () | |
BigUInt (std::uint64_t v) | |
BigUInt (std::string const &s) | |
operator bool () const noexcept | |
std::uint32_t & | operator[] (int i) |
std::uint32_t const & | operator[] (int i) const |
BigUInt & | operator+= (std::uint32_t b) |
BigUInt & | operator+= (BigUInt const &b) |
BigUInt & | operator-= (std::uint32_t b) |
BigUInt & | operator-= (BigUInt const &b) |
BigUInt & | operator*= (std::uint32_t b) |
BigUInt & | operator<<= (std::uint32_t b) |
BigUInt & | operator>>= (std::uint32_t b) |
Private Attributes | |
std::uint32_t | x [n] |
Arbitrary-precision unsigned integer class.
This class implements an unsigned integer type of arbitrary precision. The precision is chosen at compile time via a template parameter. The template parameter specifies how many 32-bit "digits" will compose the full integer. Thus, the number has (32*n) bits of precision.
This class was primarily created to serve the Teuchos::print_double function for printing floating-point values in a lossless and minimal way.
Definition at line 65 of file Teuchos_BigUIntDecl.hpp.
Teuchos::BigUInt< n >::BigUInt | ( | ) |
Definition at line 55 of file Teuchos_BigUInt.hpp.
Teuchos::BigUInt< n >::BigUInt | ( | std::uint64_t | v | ) |
Definition at line 58 of file Teuchos_BigUInt.hpp.
Teuchos::BigUInt< n >::BigUInt | ( | std::string const & | s | ) |
Definition at line 65 of file Teuchos_BigUInt.hpp.
|
explicitnoexcept |
Definition at line 73 of file Teuchos_BigUInt.hpp.
std::uint32_t & Teuchos::BigUInt< n >::operator[] | ( | int | i | ) |
Definition at line 79 of file Teuchos_BigUInt.hpp.
std::uint32_t const & Teuchos::BigUInt< n >::operator[] | ( | int | i | ) | const |
Definition at line 82 of file Teuchos_BigUInt.hpp.
BigUInt< n > & Teuchos::BigUInt< n >::operator+= | ( | std::uint32_t | b | ) |
Definition at line 85 of file Teuchos_BigUInt.hpp.
BigUInt< n > & Teuchos::BigUInt< n >::operator+= | ( | BigUInt< n > const & | b | ) |
Definition at line 97 of file Teuchos_BigUInt.hpp.
BigUInt< n > & Teuchos::BigUInt< n >::operator-= | ( | std::uint32_t | b | ) |
Definition at line 110 of file Teuchos_BigUInt.hpp.
BigUInt< n > & Teuchos::BigUInt< n >::operator-= | ( | BigUInt< n > const & | b | ) |
Definition at line 127 of file Teuchos_BigUInt.hpp.
BigUInt< n > & Teuchos::BigUInt< n >::operator*= | ( | std::uint32_t | b | ) |
Definition at line 145 of file Teuchos_BigUInt.hpp.
BigUInt< n > & Teuchos::BigUInt< n >::operator<<= | ( | std::uint32_t | b | ) |
Definition at line 157 of file Teuchos_BigUInt.hpp.
BigUInt< n > & Teuchos::BigUInt< n >::operator>>= | ( | std::uint32_t | b | ) |
Definition at line 175 of file Teuchos_BigUInt.hpp.
|
private |
Definition at line 67 of file Teuchos_BigUIntDecl.hpp.