This struct provides a namespace for utility functions that implement core decimal floating‐poing operations.

Synopsis

Declared in <bdldfp_decimalimputil.h>

class DecimalImpUtil;

Types

Name

Description

This_is_not_a_floating_point_literal

This struct is a helper type used to generate error messages for bad literals.

Type Aliases

Name

Description

ValueType128

Alias for the 128‐bit raw decimal value type.

ValueType32

Alias for the 32‐bit raw decimal value type.

ValueType64

Alias for the 64‐bit raw decimal value type.

Enums

Name

Description

Unnamed enum

Status flag constants for decimal numeric operations.

Static Member Functions

Name

Description

add

add overloads

binaryToDecimal128

binaryToDecimal128 overloads

binaryToDecimal32

binaryToDecimal32 overloads

binaryToDecimal64

binaryToDecimal64 overloads

ceil

ceil overloads

checkLiteral

checkLiteral overloads

classify

classify overloads

convertBIDtoDPD

convertBIDtoDPD overloads

convertDPDtoBID

convertDPDtoBID overloads

convertFromBID

convertFromBID overloads

convertToBID

convertToBID overloads

convertToDecimal128

convertToDecimal128 overloads

convertToDecimal32

convertToDecimal32 overloads

convertToDecimal64

convertToDecimal64 overloads

copySign

copySign overloads

decompose

decompose overloads

denormMin128

Return the smallest positive denormalized value for the ValueType128 type (IEEE‐754: +0.000000000000000000000000000000001e‐6143).

denormMin32

Return the smallest positive denormalized value for the ValueType32 type (IEEE‐754: +0.000001e‐95).

denormMin64

Return the smallest positive denormalized value for the ValueType64 type (IEEE‐754: +0.000000000000001e‐383).

divide

divide overloads

epsilon128

Return the difference between the least representable value of type ValueType128 greater than 1 and 1 (IEEE‐754: +1e‐33).

epsilon32

Return the difference between the least representable value of type ValueType32 greater than 1 and 1 (IEEE‐754: +1e‐6).

epsilon64

Return the difference between the least representable value of type ValueType64 greater than 1 and 1 (IEEE‐754: +1e‐15).

equal

equal overloads

exp

exp overloads

fabs

fabs overloads

floor

floor overloads

fma

fma overloads

fmod

fmod overloads

format

format overloads

greater

greater overloads

greaterEqual

greaterEqual overloads

infinity128

Return the value that represents positive infinity for the ValueType128 type.

infinity32

Return the value that represents positive infinity for the ValueType32 type.

infinity64

Return the value that represents positive infinity for the ValueType64 type.

int32ToDecimal128

Return a 128‐bit decimal representation of the specified integer.

int32ToDecimal32

Return a 32‐bit decimal representation of the specified integer.

int32ToDecimal64

Return a 64‐bit decimal representation of the specified int value. Return a 64‐bit decimal representation of the specified integer.

int64ToDecimal128

Return a 128‐bit decimal representation of the specified 64‐bit integer.

int64ToDecimal32

Return a 32‐bit decimal representation of the specified 64‐bit signed integer.

int64ToDecimal64

Return a 64‐bit decimal representation of the specified value.

less

less overloads

lessEqual

lessEqual overloads

llrint

llrint overloads

log

log overloads

log10

log10 overloads

logB

logB overloads

lrint

Return x rounded to the nearest long int.

lround

lround overloads

makeDecimal64

makeDecimal64 overloads

makeDecimalRaw128

makeDecimalRaw128 overloads

makeDecimalRaw32

Create a ValueType32 object representing a decimal floating point number consisting of the specified significand and exponent, with the sign given by significand. The behavior is undefined unless abs(significand) <= 9,999,999 and ‐101 <= exponent <= 90.

makeDecimalRaw64

makeDecimalRaw64 overloads

makeInfinity64

Return a ValueType64 representing infinity. Optionally specify whether the infinity isNegative. If isNegative is false or is is not supplied, the returned value will be infinity, and negative infinity otherwise.

max128

Return the largest number ValueType128 can represent (IEEE‐754: +9.999999999999999999999999999999999e+6144).

max32

Return the largest number ValueType32 can represent (IEEE‐754: +9.999999e+96).

max64

Return the largest number ValueType64 can represent (IEEE‐754: +9.999999999999999e+384).

min128

Return the smallest positive normalized number ValueType128 can represent (IEEE‐754: +1e‐6143).

min32

Return the smallest positive normalized number ValueType32 can represent (IEEE‐754: +1e‐95).

min64

Return the smallest positive normalized number ValueType64 can represent (IEEE‐754: +1e‐383).

multiply

multiply overloads

negate

negate overloads

nextafter

Return the next representable value after from toward to.

nexttoward

nexttoward overloads

normalize

normalize overloads

notEqual

notEqual overloads

parse128

parse128 overloads

parse32

Parse a 32‐bit decimal value from the specified input string.

parse64

Parse a 64‐bit decimal value from the specified input string.

pow

pow overloads

quantize

quantize overloads

quantizeEqual

quantizeEqual overloads

quietNaN128

Return a value that represents non‐signaling NaN for the ValueType128 type.

quietNaN32

Return a value that represents non‐signaling NaN for the ValueType32 type.

quietNaN64

Return a value that represents non‐signaling NaN for the ValueType64 type.

remainder

remainder overloads

round

round overloads

roundError128

Return the maximum rounding error for the ValueType128 type. The actual value returned depends on the current decimal floating point rounding setting.

roundError32

Return the maximum rounding error for the ValueType32 type. The actual value returned depends on the current decimal floating point rounding setting.

roundError64

Return the maximum rounding error for the ValueType64 type. The actual value returned depends on the current decimal floating point rounding setting.

sameQuantum

sameQuantum overloads

scaleB

scaleB overloads

signalingNaN128

Return a value that represents signaling NaN for the ValueType128 type.

signalingNaN32

Return a value that represents signaling NaN for the ValueType32 type.

signalingNaN64

Return a value that represents signaling NaN for the ValueType64 type.

sqrt

Return the square root of the specified x.

subtract

subtract overloads

trunc

trunc overloads

uint32ToDecimal128

Return a 128‐bit decimal representation of the specified unsigned integer.

uint32ToDecimal32

Return a 32‐bit decimal representation of the specified unsigned integer.

uint32ToDecimal64

Return a 64‐bit decimal representation of the specified unsigned int value.

uint64ToDecimal128

Return a Decimal128 object having the value closest to the specified value subject to the conversion rules as defined by IEEE‐754:

uint64ToDecimal32

Return a Decimal32 object having the value closest to the specified value following the conversion rules as defined by IEEE‐754:

uint64ToDecimal64

Return a Decimal64 object having the value closest to the specified value following the conversion rules as defined by IEEE‐754:

Created with MrDocs