The OpenD Programming Language

deserializeValueImpl

Deserialize decimal value.

Examples

import mir.ion.value;
import mir.ion.exception;
import mir.bignum.decimal;

Decimal!128 value; // 256x64 bits

// from ion decimal
auto data = IonValue([0x56, 0x00, 0xcb, 0x80, 0xbc, 0x2d, 0x86]).describe;

assert(deserializeValueImpl(data, value) == IonErrorCode.none);
assert(cast(double)value == -12332422e75);

Meta