From c6549eddb59d7d044f70f7f7973ac8b5480ae761 Mon Sep 17 00:00:00 2001 From: "Claudius \"keldu\" Holeksa" Date: Sat, 7 Jun 2025 15:33:51 +0200 Subject: Added class struct impl base for Json FixedArray decoding. Not implemented yet, but shouldn't cause compilation errors either --- modules/codec-json/c++/json.tmpl.hpp | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) (limited to 'modules/codec-json/c++/json.tmpl.hpp') diff --git a/modules/codec-json/c++/json.tmpl.hpp b/modules/codec-json/c++/json.tmpl.hpp index a6d4a20..956393f 100644 --- a/modules/codec-json/c++/json.tmpl.hpp +++ b/modules/codec-json/c++/json.tmpl.hpp @@ -874,7 +874,7 @@ struct json_decode, ToDecode> { } }; -// The whole std::vector approach is hacky af. ToDo change it maybe? +// The whole std::vector approach is hacky af. TODO change it maybe? template struct json_decode, ToDecode> { using Schema = schema::Array; @@ -979,5 +979,15 @@ struct json_decode, ToDecode> { return decode_unflat_level<0>(flat_array, to, index, flat_index); } }; + +template +struct json_decode, ToDecode> { + using Schema = schema::FixedArray; + + static error_or decode(buffer_view& buff, data& to){ + + return make_error("Json FixedArray decoding not implemented."); + } +}; } } -- cgit v1.2.3