From 9e5738a86af1bc50480b0263664057b665b94cba Mon Sep 17 00:00:00 2001 From: Behdad Esfahbod Date: Wed, 26 May 2021 15:12:39 -0600 Subject: [PATCH] [set] Okay, giving up on constexpr till C++14 ../src/hb-set.hh:213:89: error: call to non-'constexpr' function 'const elt_t& hb_vector_size_t::operator[](unsigned int) const [with elt_t = long long unsigned int; unsigned int byte_size = 64]' --- src/hb-set.hh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/hb-set.hh b/src/hb-set.hh index 79217ef20..4bbca903d 100644 --- a/src/hb-set.hh +++ b/src/hb-set.hh @@ -70,7 +70,7 @@ struct hb_set_t void add (hb_codepoint_t g) { elt (g) |= mask (g); } void del (hb_codepoint_t g) { elt (g) &= ~mask (g); } - constexpr bool get (hb_codepoint_t g) const { return elt (g) & mask (g); } + bool get (hb_codepoint_t g) const { return elt (g) & mask (g); } void add_range (hb_codepoint_t a, hb_codepoint_t b) { @@ -210,7 +210,7 @@ struct hb_set_t static_assert ((unsigned) PAGE_BITS == (unsigned) BITS, ""); elt_t &elt (hb_codepoint_t g) { return v[(g & MASK) / ELT_BITS]; } - constexpr elt_t const &elt (hb_codepoint_t g) const { return v[(g & MASK) / ELT_BITS]; } + const elt_t& elt (hb_codepoint_t g) const { return v[(g & MASK) / ELT_BITS]; } static constexpr elt_t mask (hb_codepoint_t g) { return elt_t (1) << (g & ELT_MASK); } vector_t v;