diff options
author | Behdad Esfahbod <behdad@behdad.org> | 2018-11-29 14:53:43 -0500 |
---|---|---|
committer | Behdad Esfahbod <behdad@behdad.org> | 2018-11-29 14:56:27 -0500 |
commit | 44cbd2ea3dc36312bd80860983b6616586e78c6c (patch) | |
tree | dd440ccda90307eeaf1c577fe82f4e496c06a13d | |
parent | 861bc75349257f74c12b261abfcd5ab9e2f04863 (diff) | |
download | harfbuzz-44cbd2ea3dc36312bd80860983b6616586e78c6c.tar.gz |
Convert "static const bool" constants to anonymous enum
-rw-r--r-- | src/hb-aat-layout-common.hh | 4 | ||||
-rw-r--r-- | src/hb-aat-layout-kerx-table.hh | 4 | ||||
-rw-r--r-- | src/hb-aat-layout-morx-table.hh | 8 | ||||
-rw-r--r-- | src/hb-dsalgs.hh | 16 | ||||
-rw-r--r-- | src/hb-ot-kern-table.hh | 4 | ||||
-rw-r--r-- | src/hb-ot-layout.cc | 4 |
6 files changed, 20 insertions, 20 deletions
diff --git a/src/hb-aat-layout-common.hh b/src/hb-aat-layout-common.hh index c0b0e375..588dbdf2 100644 --- a/src/hb-aat-layout-common.hh +++ b/src/hb-aat-layout-common.hh @@ -675,7 +675,7 @@ struct ClassTable struct ObsoleteTypes { - static const bool extended = false; + enum { extended = false }; typedef HBUINT16 HBUINT; typedef HBUINT8 HBUSHORT; typedef ClassTable<HBUINT8> ClassTypeNarrow; @@ -705,7 +705,7 @@ struct ObsoleteTypes }; struct ExtendedTypes { - static const bool extended = true; + enum { extended = true }; typedef HBUINT32 HBUINT; typedef HBUINT16 HBUSHORT; typedef Lookup<HBUINT16> ClassTypeNarrow; diff --git a/src/hb-aat-layout-kerx-table.hh b/src/hb-aat-layout-kerx-table.hh index 7caf45d5..d0b44609 100644 --- a/src/hb-aat-layout-kerx-table.hh +++ b/src/hb-aat-layout-kerx-table.hh @@ -211,7 +211,7 @@ struct KerxSubTableFormat1 struct driver_context_t { - static const bool in_place = true; + enum { in_place = true }; enum { DontAdvance = Format1EntryT::DontAdvance, @@ -472,7 +472,7 @@ struct KerxSubTableFormat4 struct driver_context_t { - static const bool in_place = true; + enum { in_place = true }; enum Flags { Mark = 0x8000, /* If set, remember this glyph as the marked glyph. */ diff --git a/src/hb-aat-layout-morx-table.hh b/src/hb-aat-layout-morx-table.hh index 171ee4a1..e8a0cdfc 100644 --- a/src/hb-aat-layout-morx-table.hh +++ b/src/hb-aat-layout-morx-table.hh @@ -54,7 +54,7 @@ struct RearrangementSubtable struct driver_context_t { - static const bool in_place = true; + enum { in_place = true }; enum Flags { MarkFirst = 0x8000, /* If set, make the current glyph the first @@ -204,7 +204,7 @@ struct ContextualSubtable struct driver_context_t { - static const bool in_place = true; + enum { in_place = true }; enum Flags { SetMark = 0x8000, /* If set, make the current glyph the marked glyph. */ @@ -424,7 +424,7 @@ struct LigatureSubtable struct driver_context_t { - static const bool in_place = false; + enum { in_place = false }; enum { DontAdvance = LigatureEntryT::DontAdvance, @@ -660,7 +660,7 @@ struct InsertionSubtable struct driver_context_t { - static const bool in_place = false; + enum { in_place = false }; enum Flags { SetMark = 0x8000, /* If set, mark the current glyph. */ diff --git a/src/hb-dsalgs.hh b/src/hb-dsalgs.hh index 57735960..4a8144ba 100644 --- a/src/hb-dsalgs.hh +++ b/src/hb-dsalgs.hh @@ -735,26 +735,26 @@ inline hb_sorted_array_t<T> hb_sorted_array (T *array, unsigned int len) struct HbOpOr { - static const bool passthru_left = true; - static const bool passthru_right = true; + enum { passthru_left = true }; + enum { passthru_right = true }; template <typename T> static void process (T &o, const T &a, const T &b) { o = a | b; } }; struct HbOpAnd { - static const bool passthru_left = false; - static const bool passthru_right = false; + enum { passthru_left = false }; + enum { passthru_right = false }; template <typename T> static void process (T &o, const T &a, const T &b) { o = a & b; } }; struct HbOpMinus { - static const bool passthru_left = true; - static const bool passthru_right = false; + enum { passthru_left = true }; + enum { passthru_right = false }; template <typename T> static void process (T &o, const T &a, const T &b) { o = a & ~b; } }; struct HbOpXor { - static const bool passthru_left = true; - static const bool passthru_right = true; + enum { passthru_left = true }; + enum { passthru_right = true }; template <typename T> static void process (T &o, const T &a, const T &b) { o = a ^ b; } }; diff --git a/src/hb-ot-kern-table.hh b/src/hb-ot-kern-table.hh index b57ebaea..3b71ac80 100644 --- a/src/hb-ot-kern-table.hh +++ b/src/hb-ot-kern-table.hh @@ -160,7 +160,7 @@ struct KernSubTable struct KernOTSubTableHeader { - static const bool apple = false; + enum { apple = false }; typedef AAT::ObsoleteTypes Types; inline unsigned int tuple_count (void) const { return 0; } @@ -215,7 +215,7 @@ struct KernOT : AAT::KerxTable<KernOT> struct KernAATSubTableHeader { - static const bool apple = true; + enum { apple = true }; typedef AAT::ObsoleteTypes Types; inline unsigned int tuple_count (void) const { return 0; } diff --git a/src/hb-ot-layout.cc b/src/hb-ot-layout.cc index d0b22efe..b08ee7f6 100644 --- a/src/hb-ot-layout.cc +++ b/src/hb-ot-layout.cc @@ -1299,7 +1299,7 @@ hb_ot_layout_feature_get_characters (hb_face_t *face, struct GSUBProxy { enum { table_index = 0 }; - static const bool inplace = false; + enum { inplace = false }; typedef OT::SubstLookup Lookup; GSUBProxy (hb_face_t *face) : @@ -1313,7 +1313,7 @@ struct GSUBProxy struct GPOSProxy { enum { table_index = 1 }; - static const bool inplace = true; + enum { inplace = true }; typedef OT::PosLookup Lookup; GPOSProxy (hb_face_t *face) : |