JsonVariant automatically promotes to JsonObject or JsonArray on write

This commit is contained in:
Benoit Blanchon
2019-01-29 14:09:09 +01:00
parent 5aea1363cc
commit 6f55d1e58f
53 changed files with 1197 additions and 541 deletions

View File

@@ -40,7 +40,8 @@ void objectRemove(CollectionData *obj, TKey key) {
}
template <typename TKey>
inline VariantData *objectSet(CollectionData *obj, TKey key, MemoryPool *pool) {
inline VariantData *objectGetOrCreate(CollectionData *obj, TKey key,
MemoryPool *pool) {
if (!obj) return 0;
// ignore null key