The OpenD Programming Language

deserializeValueImpl

Examples

import mir.ion.exception;
import mir.ion.value;
import mir.rc.array: RCArray;

auto data = IonValue([
    0xbe, 0x91, 0x00, 0x00, 0x21, 0x0c,
    0x00, 0x00, 0x48, 0x43, 0x0c, 0x6b,
    0xf5, 0x26, 0x34, 0x00, 0x00, 0x00,
    0x00]).describe;

RCArray!(const double) value;
assert(deserializeValueImpl(data, value) == IonErrorCode.none);
assert(value[] == [12, 100e13]);

Meta