[JSON] initialise all member variables. Maybe this will shut valgrind up. std::tie probably wasn't the problem initially

This commit is contained in:
pf 2020-07-20 10:51:43 +01:00
parent 7660ea12f6
commit 35b899e988

View file

@ -137,32 +137,32 @@ class person_with_private_alphabet
} }
private: private:
int a; int a = 0;
int b; int b = 0;
int c; int c = 0;
int d; int d = 0;
int e; int e = 0;
int f; int f = 0;
int g; int g = 0;
int h; int h = 0;
int i; int i = 0;
int j; int j = 0;
int k; int k = 0;
int l; int l = 0;
int m; int m = 0;
int n; int n = 0;
int o; int o = 0;
int p; int p = 0;
int q; int q = 0;
int r; int r = 0;
int s; int s = 0;
int t; int t = 0;
int u; int u = 0;
int v; int v = 0;
int w; int w = 0;
int x; int x = 0;
int y; int y = 0;
int z; int z = 0;
NLOHMANN_DEFINE_TYPE_INTRUSIVE(person_with_private_alphabet, a, b, c, d, e, f, g, h, i, j, k, l, m, n, o, p, q, r, s, t, u, v, w, x, y, z) NLOHMANN_DEFINE_TYPE_INTRUSIVE(person_with_private_alphabet, a, b, c, d, e, f, g, h, i, j, k, l, m, n, o, p, q, r, s, t, u, v, w, x, y, z)
}; };
@ -199,32 +199,32 @@ class person_with_public_alphabet
z == other.z; z == other.z;
} }
int a; int a = 0;
int b; int b = 0;
int c; int c = 0;
int d; int d = 0;
int e; int e = 0;
int f; int f = 0;
int g; int g = 0;
int h; int h = 0;
int i; int i = 0;
int j; int j = 0;
int k; int k = 0;
int l; int l = 0;
int m; int m = 0;
int n; int n = 0;
int o; int o = 0;
int p; int p = 0;
int q; int q = 0;
int r; int r = 0;
int s; int s = 0;
int t; int t = 0;
int u; int u = 0;
int v; int v = 0;
int w; int w = 0;
int x; int x = 0;
int y; int y = 0;
int z; int z = 0;
}; };
NLOHMANN_DEFINE_TYPE_NON_INTRUSIVE(person_with_public_alphabet, a, b, c, d, e, f, g, h, i, j, k, l, m, n, o, p, q, r, s, t, u, v, w, x, y, z) NLOHMANN_DEFINE_TYPE_NON_INTRUSIVE(person_with_public_alphabet, a, b, c, d, e, f, g, h, i, j, k, l, m, n, o, p, q, r, s, t, u, v, w, x, y, z)