[cff-common] Use range-based loop in str_buff_vec_t

This commit is contained in:
Behdad Esfahbod 2022-05-09 15:40:55 -06:00
parent 8bb1a3ce9a
commit 258afb45b7
1 changed files with 2 additions and 2 deletions

View File

@ -58,8 +58,8 @@ struct str_buff_vec_t : hb_vector_t<str_buff_t>
unsigned int total_size () const unsigned int total_size () const
{ {
unsigned int size = 0; unsigned int size = 0;
for (unsigned int i = 0; i < length; i++) for (const auto& v : *this )
size += (*this)[i].length; size += v.length;
return size; return size;
} }