File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -1936,7 +1936,12 @@ class GenericValue {
19361936 if (count) {
19371937 GenericValue* e = static_cast <GenericValue*>(allocator.Malloc (count * sizeof (GenericValue)));
19381938 SetElementsPointer (e);
1939+ RAPIDJSON_DIAG_PUSH
1940+ #if defined(__GNUC__) && __GNUC__ >= 8
1941+ RAPIDJSON_DIAG_OFF (class -memaccess) // ignore complains from gcc that no trivial copy constructor exists.
1942+ #endif
19391943 std::memcpy (e, values, count * sizeof (GenericValue));
1944+ RAPIDJSON_DIAG_POP
19401945 }
19411946 else
19421947 SetElementsPointer (0 );
@@ -1949,7 +1954,12 @@ class GenericValue {
19491954 if (count) {
19501955 Member* m = static_cast <Member*>(allocator.Malloc (count * sizeof (Member)));
19511956 SetMembersPointer (m);
1957+ RAPIDJSON_DIAG_PUSH
1958+ #if defined(__GNUC__) && __GNUC__ >= 8
1959+ RAPIDJSON_DIAG_OFF (class -memaccess) // ignore complains from gcc that no trivial copy constructor exists.
1960+ #endif
19521961 std::memcpy (m, members, count * sizeof (Member));
1962+ RAPIDJSON_DIAG_POP
19531963 }
19541964 else
19551965 SetMembersPointer (0 );
You can’t perform that action at this time.
0 commit comments