diff --git a/src/hb-algs.hh b/src/hb-algs.hh index d377772e0..0db2184cf 100644 --- a/src/hb-algs.hh +++ b/src/hb-algs.hh @@ -41,6 +41,13 @@ struct } HB_FUNCOBJ (hb_identity); +struct +{ + template hb_remove_reference + operator () (T&& v) const { return v; } +} +HB_FUNCOBJ (hb_rvalue); + struct { template bool diff --git a/src/hb-map.hh b/src/hb-map.hh index 6eac8c3d3..2f0659562 100644 --- a/src/hb-map.hh +++ b/src/hb-map.hh @@ -221,12 +221,14 @@ struct hb_hashmap_t + hb_array (items, mask ? mask + 1 : 0) | hb_filter (&item_t::is_real) | hb_map (&item_t::key) + | hb_map (hb_rvalue) ) auto values () const HB_AUTO_RETURN ( + hb_array (items, mask ? mask + 1 : 0) | hb_filter (&item_t::is_real) | hb_map (&item_t::value) + | hb_map (hb_rvalue) ) protected: