1
0
mirror of synced 2026-04-14 01:13:58 +00:00

json.h: Fix array template

Using `{begin|end}_object` inserts curly braces instead of square brackets, which can result in reordering (and may be syntactically incorrect?).
This commit is contained in:
Krystine Sherwin
2025-07-21 10:32:09 +12:00
parent fe3adfd960
commit 2c79aeb7ad

View File

@@ -90,10 +90,10 @@ public:
template<typename T>
void array(const T &&values)
{
begin_object();
begin_array();
for (auto &item : values)
value(item);
end_object();
end_array();
}
};