Remove NullPool visibility hack
authorBehdad Esfahbod <behdad@behdad.org>
Wed, 7 Feb 2018 17:44:35 +0000 (12:44 -0500)
committerBehdad Esfahbod <behdad@behdad.org>
Wed, 7 Feb 2018 17:44:35 +0000 (12:44 -0500)
We keep a separate private NullPool in libharfbuzz-subset.so
This can fire back later since now there are two separate null objects,
and comparisons to the null pool can be confused.  Something to deal
with when it comes up. Ouch!

src/hb-open-type-private.hh
src/hb-subset.cc

index 959f743b9ad7122dbd6a1fc06997492513c4a90c..04e4a4e1ba9d42a8228a0a68347531d234c29a77 100644 (file)
@@ -134,9 +134,7 @@ static inline Type& StructAfter(TObject &X)
 
 #define HB_NULL_POOL_SIZE 264
 static_assert (HB_NULL_POOL_SIZE % sizeof (void *) == 0, "Align HB_NULL_POOL_SIZE.");
-// TODO add back HB_INTERNAL once we figure out how to not have that break
-// subset compile
-extern const void * const _hb_NullPool[HB_NULL_POOL_SIZE / sizeof (void *)];
+extern HB_INTERNAL const void * const _hb_NullPool[HB_NULL_POOL_SIZE / sizeof (void *)];
 
 /* Generic nul-content Null objects. */
 template <typename Type>
index 5849efd2e86945c6de02e9e02267d09576210fd1..7215b60b01a1ecb34ffb512acc8a082d311842dc 100644 (file)
 
 #include "hb-ot-glyf-table.hh"
 
+
+const void * const OT::_hb_NullPool[HB_NULL_POOL_SIZE / sizeof (void *)] = {};
+
+
 struct hb_subset_profile_t {
   hb_object_header_t header;
   ASSERT_POD ();