提交 04f7e553 编写于 作者: B Behdad Esfahbod

[arrays] Add as_array() to hb_vector_t<>

上级 c514f651
......@@ -89,6 +89,9 @@ struct hb_vector_t
return arrayZ()[i];
}
inline hb_array_t<Type> as_array (void) { return hb_array_t<Type> (arrayZ(), len); }
inline hb_array_t<const Type> as_array (void) const { return hb_array_t<const Type> (arrayZ(), len); }
template <typename T> inline operator T * (void) { return arrayZ(); }
template <typename T> inline operator const T * (void) const { return arrayZ(); }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册