================
@@ -453,10 +458,12 @@ static void serializeArray(const Container &Records, 
Object &Obj,
     auto &ItemObj = *ItemVal.getAsObject();
     SerializeInfo(Records[Index], ItemObj);
     if (Index == Records.size() - 1)
-      ItemObj["End"] = true;
+      ItemObj[EndKey] = true;
     RecordsArrayRef.push_back(ItemVal);
   }
   Obj[Key] = RecordsArray;
+  if (Customize)
+    Customize(Obj, Records.size());
----------------
ilovepi wrote:

If the callback is an std::function, you can always just call it. It can have a 
default implementation that does nothing.

```cpp
..., std::function<void(Object&)> UpdateJSON = [](Object& Obj){}) {
//...
UpdateJSON(Obj);
```


https://github.com/llvm/llvm-project/pull/181417
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to