[HarfBuzz] harfbuzz: Branch 'master'

Behdad Esfahbod behdad at kemper.freedesktop.org
Fri Nov 30 17:52:55 UTC 2018


 src/hb-ot-name-table.hh |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

New commits:
commit f998bb2086342d6fdcd4295593eddea91396e0b6
Author: Behdad Esfahbod <behdad at behdad.org>
Date:   Fri Nov 30 12:52:21 2018 -0500

    More weird fixes
    
    In file included from hb-ot-name.cc:29:
    hb-ot-name-table.hh: In member function 'unsigned int OT::name::get_size() const':
    hb-ot-name-table.hh:157: error: ISO C++ says that these are ambiguous, even though the worst conversion for the first is better than the worst conversion for the second:
    hb-open-type.hh:354: note: candidate 1: const Type& OT::UnsizedArrayOf<Type>::operator[](unsigned int) const [with Type = OT::NameRecord]
    hb-ot-name-table.hh:157: note: candidate 2: operator[](const T*, int) <built-in>
    hb-ot-name-table.hh: In member function 'void OT::name::accelerator_t::init(hb_face_t*)':
    hb-ot-name-table.hh:196: error: ISO C++ says that these are ambiguous, even though the worst conversion for the first is better than the worst conversion for the second:
    hb-dsalgs.hh:574: note: candidate 1: Type& hb_array_t<Type>::operator[](unsigned int) const [with Type = const OT::NameRecord]
    hb-ot-name-table.hh:196: note: candidate 2: operator[](T*, int) <built-in>
    hb-ot-name-table.hh:197: error: ISO C++ says that these are ambiguous, even though the worst conversion for the first is better than the worst conversion for the second:
    hb-dsalgs.hh:574: note: candidate 1: Type& hb_array_t<Type>::operator[](unsigned int) const [with Type = const OT::NameRecord]
    hb-ot-name-table.hh:197: note: candidate 2: operator[](T*, int) <built-in>
    hb-ot-name-table.hh:198: error: ISO C++ says that these are ambiguous, even though the worst conversion for the first is better than the worst conversion for the second:
    hb-dsalgs.hh:574: note: candidate 1: Type& hb_array_t<Type>::operator[](unsigned int) const [with Type = const OT::NameRecord]
    hb-ot-name-table.hh:198: note: candidate 2: operator[](T*, int) <built-in>
    make[4]: *** [libharfbuzz_la-hb-ot-name.lo] Error 1
    make[3]: *** [all-recursive] Error 1

diff --git a/src/hb-ot-name-table.hh b/src/hb-ot-name-table.hh
index 4f24d737..a903e1cd 100644
--- a/src/hb-ot-name-table.hh
+++ b/src/hb-ot-name-table.hh
@@ -154,7 +154,7 @@ struct name
   enum { tableTag = HB_OT_TAG_name };
 
   inline unsigned int get_size (void) const
-  { return min_size + count * nameRecordZ[0].min_size; }
+  { return min_size + count * nameRecordZ.item_size; }
 
   inline bool sanitize_records (hb_sanitize_context_t *c) const {
     TRACE_SANITIZE (this);
@@ -189,7 +189,7 @@ struct name
       this->names.init ();
       this->names.alloc (all_names.len);
 
-      for (uint16_t i = 0; i < all_names.len; i++)
+      for (unsigned int i = 0; i < all_names.len; i++)
       {
 	hb_ot_name_entry_t *entry = this->names.push ();
 


More information about the HarfBuzz mailing list