From a87843be3dea86a5893e1fa64667df872408549e Mon Sep 17 00:00:00 2001 From: Behdad Esfahbod Date: Mon, 14 Nov 2022 13:43:58 -0700 Subject: [PATCH] [array] Another try at sizeof sorted_array --- src/hb-array.hh | 8 ++++---- src/test-array.cc | 3 +-- 2 files changed, 5 insertions(+), 6 deletions(-) diff --git a/src/hb-array.hh b/src/hb-array.hh index 5884007c1..955373662 100644 --- a/src/hb-array.hh +++ b/src/hb-array.hh @@ -295,8 +295,8 @@ hb_array (T (&array_)[length_]) template struct hb_sorted_array_t : - hb_iter_t, Type&>, - hb_array_t + hb_array_t, + hb_iter_t, Type&> { typedef hb_iter_t iter_base_t; HB_ITER_USING (iter_base_t); @@ -316,8 +316,8 @@ struct hb_sorted_array_t : template constexpr hb_sorted_array_t (const hb_array_t &o) : - hb_iter_t (), - hb_array_t (o) {} + hb_array_t (o), + hb_iter_t () {} template hb_sorted_array_t& operator = (const hb_array_t &o) diff --git a/src/test-array.cc b/src/test-array.cc index 28cd02364..0acf73b61 100644 --- a/src/test-array.cc +++ b/src/test-array.cc @@ -70,8 +70,7 @@ test_reverse_invalid () int main (int argc, char **argv) { - /* The following fails on MSVC. */ - // assert (sizeof (hb_array_t) == sizeof (hb_sorted_array_t)); + assert (sizeof (hb_array_t) == sizeof (hb_sorted_array_t)); test_reverse (); test_reverse_range ();