Minor, fix two more ArrayOf incorrect operator logic

This commit is contained in:
Ebrahim Byagowi 2018-12-17 20:07:04 +03:30 committed by GitHub
parent a1240383aa
commit 7ace10078c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 2 deletions

View File

@ -382,7 +382,7 @@ struct UnsizedArrayOf
hb_array_t<const Type> as_array (unsigned int len) const hb_array_t<const Type> as_array (unsigned int len) const
{ return hb_array (arrayZ, len); } { return hb_array (arrayZ, len); }
operator hb_array_t<Type> (void) { return as_array (); } operator hb_array_t<Type> (void) { return as_array (); }
operator hb_array_t<const Type> (void) const { as_array (); } operator hb_array_t<const Type> (void) const { return as_array (); }
template <typename T> template <typename T>
Type &lsearch (unsigned int len, const T &x, Type &not_found = Crap (Type)) Type &lsearch (unsigned int len, const T &x, Type &not_found = Crap (Type))
@ -534,7 +534,7 @@ struct ArrayOf
hb_array_t<const Type> as_array (void) const hb_array_t<const Type> as_array (void) const
{ return hb_array (arrayZ, len); } { return hb_array (arrayZ, len); }
operator hb_array_t<Type> (void) { return as_array (); } operator hb_array_t<Type> (void) { return as_array (); }
operator hb_array_t<const Type> (void) const { as_array (); } operator hb_array_t<const Type> (void) const { return as_array (); }
hb_array_t<const Type> sub_array (unsigned int start_offset, unsigned int count) const hb_array_t<const Type> sub_array (unsigned int start_offset, unsigned int count) const
{ return as_array ().sub_array (start_offset, count);} { return as_array ().sub_array (start_offset, count);}