[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<elt_t, byte_size>::operator[](unsigned int) const [with elt_t = long long unsigned int; unsigned int byte_size = 64]'
This commit is contained in:
parent
fac0bc7876
commit
9e5738a86a
@ -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;
|
||||
|
Loading…
Reference in New Issue
Block a user