Changed return type of convertToJson() and Converter::toJson() to void

This commit is contained in:
Benoit Blanchon
2021-07-23 13:23:48 +02:00
parent f5c7a6478e
commit 4073b52c00
9 changed files with 54 additions and 58 deletions

View File

@@ -173,8 +173,8 @@ class ArrayRef : public ArrayRefBase<CollectionData>,
template <>
struct Converter<ArrayConstRef> {
static bool toJson(VariantConstRef src, VariantRef dst) {
return variantCopyFrom(getData(dst), getData(src), getPool(dst));
static void toJson(VariantConstRef src, VariantRef dst) {
variantCopyFrom(getData(dst), getData(src), getPool(dst));
}
static ArrayConstRef fromJson(VariantConstRef src) {
@@ -189,8 +189,8 @@ struct Converter<ArrayConstRef> {
template <>
struct Converter<ArrayRef> {
static bool toJson(VariantConstRef src, VariantRef dst) {
return variantCopyFrom(getData(dst), getData(src), getPool(dst));
static void toJson(VariantConstRef src, VariantRef dst) {
variantCopyFrom(getData(dst), getData(src), getPool(dst));
}
static ArrayRef fromJson(VariantRef src) {

View File

@@ -178,8 +178,8 @@ class ElementProxy : public VariantOperators<ElementProxy<TArray> >,
return _array.getOrAddElement(_index);
}
friend bool convertToJson(const this_type& src, VariantRef dst) {
return dst.set(src.getUpstreamElement());
friend void convertToJson(const this_type& src, VariantRef dst) {
dst.set(src.getUpstreamElement());
}
TArray _array;