Deserializer

- Added boolean support
This commit is contained in:
Tristan B. Velloza Kildaire 2023-06-23 09:06:35 +02:00
parent 498251d255
commit d8b59673c3
1 changed files with 6 additions and 0 deletions

View File

@ -147,6 +147,12 @@ public RecordType fromJSON(RecordType)(JSONValue jsonIn)
{
mixin("record."~structNames[cnt])~= cast(ulong)jsonVal.uinteger();
}
else static if(__traits(isSame, ForeachType!(structTypes[cnt]), bool))
{
mixin("record."~structNames[cnt])~= jsonVal.boolean();
}
}