diff --git a/src/hb-meta.hh b/src/hb-meta.hh index a303c67a7..63c8a8cf5 100644 --- a/src/hb-meta.hh +++ b/src/hb-meta.hh @@ -72,6 +72,17 @@ static const struct } hb_deref_pointer HB_UNUSED; +/* std::move and std::forward */ + +template +hb_remove_reference (T)&& hb_move (T&& t) { return (hb_remove_reference (T)&&) (t); } + +template +T&& hb_forward (hb_remove_reference (T)& t) { return (T&&) t; } +template +T&& hb_forward (hb_remove_reference (T)&& t) { return (T&&) t; } + + /* Void! For when we need a expression-type of void. */ struct hb_void_t { typedef void value; };