diff --git a/src/hb-blob.cc b/src/hb-blob.cc index f90f97e78148159c7ff2b0d90dd6faa99a5f064f..3cc2d9d71032af0469b523e4ab51a2e02e508845 100644 --- a/src/hb-blob.cc +++ b/src/hb-blob.cc @@ -48,6 +48,7 @@ struct _hb_blob_t { hb_object_header_t header; + ASSERT_POD (); bool immutable; diff --git a/src/hb-buffer-private.hh b/src/hb-buffer-private.hh index fb1c801205b3f6055a316feef018c28cc0ef6114..b539f265604785f564a58d2f69d6b4fa7bf6cb01 100644 --- a/src/hb-buffer-private.hh +++ b/src/hb-buffer-private.hh @@ -44,11 +44,13 @@ typedef struct _hb_segment_properties_t { hb_direction_t direction; hb_script_t script; hb_language_t language; + ASSERT_POD (); } hb_segment_properties_t; struct _hb_buffer_t { hb_object_header_t header; + ASSERT_POD (); /* Information about how the text in the buffer should be treated */ diff --git a/src/hb-font-private.hh b/src/hb-font-private.hh index e10e1050fed86df9d3124d994acf7d2ba64ca21e..91a43047daeacc972eea51d899f8aaa530f06304 100644 --- a/src/hb-font-private.hh +++ b/src/hb-font-private.hh @@ -56,6 +56,7 @@ struct _hb_font_funcs_t { hb_object_header_t header; + ASSERT_POD (); hb_bool_t immutable; @@ -87,6 +88,7 @@ struct _hb_font_funcs_t { struct _hb_face_t { hb_object_header_t header; + ASSERT_POD (); hb_bool_t immutable; @@ -107,6 +109,7 @@ struct _hb_face_t { struct _hb_font_t { hb_object_header_t header; + ASSERT_POD (); hb_bool_t immutable; diff --git a/src/hb-object-private.hh b/src/hb-object-private.hh index e86a38d1f582d538cd2180f4ea012d4f7fcc16a3..96d1bd3a7cab327613a5659ae8b1f492e538bb3a 100644 --- a/src/hb-object-private.hh +++ b/src/hb-object-private.hh @@ -173,6 +173,8 @@ struct hb_object_header_t this ? ref_count.ref_count : 0); } + private: + ASSERT_POD (); }; diff --git a/src/hb-private.hh b/src/hb-private.hh index 8f821f2d6c6da34c682970f19fb91a97d39e9ab5..2ea0442d6a0e0aec914eea6148d000b8cc01fa7a 100644 --- a/src/hb-private.hh +++ b/src/hb-private.hh @@ -122,7 +122,7 @@ ASSERT_STATIC (sizeof (hb_var_int_t) == 4); /* Check _assertion in a method environment */ #define _ASSERT_POD1(_line) \ inline void _static_assertion_on_line_##_line (void) const \ - { _ASSERT_INSTANCE_POD1 (*this); /* Make sure it's POD. */ } + { _ASSERT_INSTANCE_POD1 (_line, *this); /* Make sure it's POD. */ } # define _ASSERT_POD0(_line) _ASSERT_POD1 (_line) # define ASSERT_POD() _ASSERT_POD0 (__LINE__) diff --git a/src/hb-set-private.hh b/src/hb-set-private.hh index b8407e92737ab45dca331e277c746d0037e47c5d..5cdf8a0f2b95af8ff000fba7b9a57e51f1fb6b09 100644 --- a/src/hb-set-private.hh +++ b/src/hb-set-private.hh @@ -36,6 +36,9 @@ struct _hb_set_t { + hb_object_header_t header; + ASSERT_POD (); + inline void init (void) { header.init (); clear (); @@ -158,7 +161,6 @@ struct _hb_set_t elt_t elt (hb_codepoint_t g) const { return elts[g >> SHIFT]; } elt_t mask (hb_codepoint_t g) const { return elt_t (1) << (g & MASK); } - hb_object_header_t header; elt_t elts[ELTS]; /* XXX 8kb */ ASSERT_STATIC (sizeof (elt_t) * 8 == BITS); diff --git a/src/hb-unicode-private.hh b/src/hb-unicode-private.hh index 7f719c4581970ae6b8ebfc744b05bf834c48671f..8a341747c9566de40a0ca9fdb295d43f23f35c49 100644 --- a/src/hb-unicode-private.hh +++ b/src/hb-unicode-private.hh @@ -63,6 +63,7 @@ struct _hb_unicode_funcs_t { hb_object_header_t header; + ASSERT_POD (); hb_unicode_funcs_t *parent;