The OpenD Programming Language

serdeIgnoreIfAggregate.serdeGetDeserializationKeysRecurse

Deserialization members final proxy keys (recursive)

Examples

static struct A { double g; float d; }

@serdeProxy!A
static struct B {  int f; }

@serdeProxy!(B[string])
static union C {  int f; }

@serdeProxy!(B[])
static interface E {  int f() @property; }

enum N { a, b }

static class D
{
    C c;

    @serdeProxy!(E[])
    int d;

    N e;
}

@serdeAlgebraicAnnotation("$F")
@serdeProxy!D
static struct F { int f; }

static assert (serdeGetDeserializationKeysRecurse!N == ["a", "b"], serdeGetDeserializationKeysRecurse!N);

static assert (serdeGetDeserializationKeysRecurse!F == ["a", "b", "c", "d", "e", "g"]);

import mir.algebraic;
static assert (serdeGetDeserializationKeysRecurse!(Nullable!(F, int)) == ["a", "b", "c", "d", "e", "g", "$F"]);

Meta