From e987059c618e03d2346c31ed64429d67ce0e367a Mon Sep 17 00:00:00 2001 From: Behdad Esfahbod Date: Wed, 21 Nov 2018 23:25:06 -0500 Subject: [PATCH] Minor --- src/hb-machinery.hh | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/hb-machinery.hh b/src/hb-machinery.hh index acd3aed..df5023b 100644 --- a/src/hb-machinery.hh +++ b/src/hb-machinery.hh @@ -90,7 +90,8 @@ static inline Type& StructAfter(TObject &X) /* Check that _code compiles in a method environment */ #define _DEFINE_COMPILES_ASSERTION1(_line, _code) \ inline void _compiles_assertion_on_line_##_line (void) const \ - { _code; } + { _code; } \ + static_assert (true, "") /* So we require semicolon here. */ # define _DEFINE_COMPILES_ASSERTION0(_line, _code) _DEFINE_COMPILES_ASSERTION1 (_line, _code) # define DEFINE_COMPILES_ASSERTION(_code) _DEFINE_COMPILES_ASSERTION0 (__LINE__, _code) @@ -116,7 +117,7 @@ static inline Type& StructAfter(TObject &X) #define DEFINE_SIZE_ARRAY(size, array) \ DEFINE_INSTANCE_ASSERTION (alignof (*this) == 1 && \ sizeof (*this) == (size) + VAR * sizeof ((array)[0])); \ - DEFINE_COMPILES_ASSERTION ((void) (array)[0].static_size) \ + DEFINE_COMPILES_ASSERTION ((void) (array)[0].static_size); \ enum { min_size = (size) } #define DEFINE_SIZE_ARRAY_SIZED(size, array) \ -- 2.7.4