[set] Always check population before checking for equality
authorBehdad Esfahbod <behdad@behdad.org>
Wed, 23 May 2018 03:57:19 +0000 (20:57 -0700)
committerBehdad Esfahbod <behdad@behdad.org>
Wed, 23 May 2018 03:57:19 +0000 (20:57 -0700)
src/hb-set-private.hh

index a4962bc..9a9f37f 100644 (file)
@@ -380,9 +380,7 @@ struct hb_set_t
 
   inline bool is_equal (const hb_set_t *other) const
   {
-    if (population != (unsigned int) -1 &&
-       other->population != (unsigned int) -1 &&
-       population != other->population)
+    if (get_population () != other->get_population ())
       return false;
 
     unsigned int na = pages.len;