Commit 055653668fb95a746ddc5ac3a2477581508f8450

Werner Lemberg 2014-03-06T18:56:58

Fixes for compilation with C++. * src/autofit/hbshim.c (scripts): Change type to `hb_script_t'. (af_get_coverage): Updated. (COVERAGE): Add cast.

diff --git a/ChangeLog b/ChangeLog
index 366f532..10a3a5d 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,11 @@
+2014-03-06  Werner Lemberg  <wl@gnu.org>
+
+	Fixes for compilation with C++.
+
+	* src/autofit/hbshim.c (scripts): Change type to `hb_script_t'.
+	(af_get_coverage): Updated.
+	(COVERAGE): Add cast.
+
 2014-03-06  Sean McBride  <sean@rogue-research.com>
 
 	Remove more clang analyzer warnings.
diff --git a/src/autofit/hbshim.c b/src/autofit/hbshim.c
index b601834..11fb743 100644
--- a/src/autofit/hbshim.c
+++ b/src/autofit/hbshim.c
@@ -89,7 +89,7 @@
 #define SCRIPT( s, S, d, h, sc1, sc2, sc3 )  h,
 
 
-  static const hb_tag_t  scripts[] =
+  static const hb_script_t  scripts[] =
   {
 #include "afscript.h"
   };
@@ -107,7 +107,7 @@
     hb_set_t*  gpos_lookups;  /* GPOS lookups for a given script */
     hb_set_t*  gpos_glyphs;   /* glyphs covered by GPOS lookups  */
 
-    hb_tag_t         script;
+    hb_script_t      script;
     const hb_tag_t*  coverage_tags;
     hb_tag_t         script_tags[] = { HB_TAG_NONE,
                                        HB_TAG_NONE,
@@ -380,7 +380,7 @@
           {                                               \
             {                                             \
               HB_TAG( tag1, tag2, tag3, tag4 ),           \
-              1, 0, -1                                    \
+              1, 0, (unsigned int)-1                      \
             }                                             \
           };