From 934e967507d66b44bfde76738ed90f213e6e62ac Mon Sep 17 00:00:00 2001 From: Fabian Kosmale Date: Wed, 10 Feb 2021 14:09:07 +0100 Subject: Restore String size assert Just like all of the other datastructures in qv4compileddata, changing the size of String would require an inrcement of QV4_DATA_STRUCTURE_VERSION. Change-Id: I462d04204255946d309d245bc20b044ba9d222d7 Reviewed-by: Ulf Hermann --- src/qml/common/qv4compileddata_p.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/qml/common/qv4compileddata_p.h b/src/qml/common/qv4compileddata_p.h index 76ed48913a..891541b8f4 100644 --- a/src/qml/common/qv4compileddata_p.h +++ b/src/qml/common/qv4compileddata_p.h @@ -227,6 +227,8 @@ struct String } }; +static_assert (sizeof (String) == 4, "String structure needs to have the expected size to be binary compatible on disk when generated by host compiler and loaded by target"); + struct CodeOffsetToLine { quint32_le codeOffset; quint32_le line; -- cgit v1.2.3