Move JSON_array for C++-20 compatibility (fixes #943)

This commit is contained in:
Jay Berkenbilt 2023-05-20 18:25:58 -04:00
parent 293a2e52b3
commit ef24a4151b
1 changed files with 12 additions and 10 deletions

View File

@ -374,16 +374,7 @@ class JSON
std::map<std::string, JSON> members;
std::set<std::string> parsed_keys;
};
struct JSON_array: public JSON_value
{
JSON_array() :
JSON_value(vt_array)
{
}
~JSON_array() override = default;
void write(Pipeline*, size_t depth) const override;
std::vector<JSON> elements;
};
struct JSON_array;
struct JSON_string: public JSON_value
{
JSON_string(std::string const& utf8);
@ -455,4 +446,15 @@ class JSON
std::shared_ptr<Members> m;
};
struct JSON::JSON_array: public JSON_value
{
JSON_array() :
JSON_value(vt_array)
{
}
~JSON_array() override = default;
void write(Pipeline*, size_t depth) const override;
std::vector<JSON> elements;
};
#endif // JSON_HH