quantizeEqual overloads

Synopses

Declared in <bdldfp_decimalutil.h>

Same as the related overload above for quantizeEqual.

static
int
quantizeEqual(
    Decimal128* x,
    Decimal128 y,
    int exponent);

Set x to y with the specified exponent if that value is exact.

static
int
quantizeEqual(
    Decimal32* x,
    Decimal32 y,
    int exponent);

Same as the overload taking Decimal32.

static
int
quantizeEqual(
    Decimal64* x,
    Decimal64 y,
    int exponent);

Return Value

0 on success and a non‐zero value otherwise

Parameters

Name

Description

x

receives the quantized value on success

y

value to quantize into x

exponent

desired decimal exponent

Created with MrDocs