Fix a few warnings

pull/1510/head
Behdad Esfahbod 6 years ago
parent 85003b594b
commit d25a2f1496
  1. 12
      src/hb-aat-layout-common.hh
  2. 8
      src/hb-iter.hh
  3. 2
      src/hb-null.hh
  4. 2
      src/hb-ot-cff1-table.hh
  5. 2
      src/hb-ot-cff2-table.hh
  6. 3
      src/hb-subset-cff-common.hh
  7. 3
      src/hb.hh

@ -707,22 +707,22 @@ struct ExtendedTypes
template <typename T>
static unsigned int offsetToIndex (unsigned int offset,
const void *base,
const T *array)
const void *base HB_UNUSED,
const T *array HB_UNUSED)
{
return offset;
}
template <typename T>
static unsigned int byteOffsetToIndex (unsigned int offset,
const void *base,
const T *array)
const void *base HB_UNUSED,
const T *array HB_UNUSED)
{
return offset / 2;
}
template <typename T>
static unsigned int wordOffsetToIndex (unsigned int offset,
const void *base,
const T *array)
const void *base HB_UNUSED,
const T *array HB_UNUSED)
{
return offset;
}

@ -85,8 +85,8 @@ struct hb_iter_t
protected:
hb_iter_t () {}
hb_iter_t (const hb_iter_t &o) {}
void operator = (const hb_iter_t &o) {}
hb_iter_t (const hb_iter_t &o HB_UNUSED) {}
void operator = (const hb_iter_t &o HB_UNUSED) {}
};
/* Base class for sorted iterators. Does not enforce anything.
@ -96,8 +96,8 @@ struct hb_sorted_iter_t : hb_iter_t<Iter, Item>
{
protected:
hb_sorted_iter_t () {}
hb_sorted_iter_t (const hb_sorted_iter_t &o) : hb_iter_t<Iter, Item> () {}
void operator = (const hb_sorted_iter_t &o) {}
hb_sorted_iter_t (const hb_sorted_iter_t &o) : hb_iter_t<Iter, Item> (o) {}
void operator = (const hb_sorted_iter_t &o HB_UNUSED) {}
};
/* Mixin to fill in what the subclass doesn't provide. */

@ -93,7 +93,7 @@ struct _hb_assign<T, T, _hb_bool_type<(bool) (1 + (unsigned int) T::min_size)> >
template <typename T, typename V>
static inline void hb_assign (T &o, const V v)
{ _hb_assign<T, V, _hb_bool_type<true> >::value (o, v); };
{ _hb_assign<T, V, _hb_bool_type<true> >::value (o, v); }
/*

@ -976,7 +976,7 @@ typedef dict_interpreter_t<cff1_font_dict_opset_t, cff1_font_dict_values_t> cff1
typedef CFF1Index CFF1NameIndex;
typedef CFF1IndexOf<TopDict> CFF1TopDictIndex;
}; /* namespace CFF */
} /* namespace CFF */
namespace OT {

@ -400,7 +400,7 @@ struct cff2_private_dict_opset_subset_t : dict_opset_t
typedef dict_interpreter_t<cff2_top_dict_opset_t, cff2_top_dict_values_t> cff2_top_dict_interpreter_t;
typedef dict_interpreter_t<cff2_font_dict_opset_t, cff2_font_dict_values_t> cff2_font_dict_interpreter_t;
}; /* namespace CFF */
} /* namespace CFF */
namespace OT {

@ -965,7 +965,8 @@ struct subr_subsetter_t
private:
typedef typename SUBRS::count_type subr_count_type;
};
}; /* namespace CFF */
} /* namespace CFF */
HB_INTERNAL bool
hb_plan_subset_cff_fdselect (const hb_vector_t<hb_codepoint_t> &glyphs,

@ -468,7 +468,8 @@ typedef uint64_t hb_vector_size_impl_t;
static inline T& operator |= (T &l, T r) { l = l | r; return l; } \
static inline T& operator &= (T& l, T r) { l = l & r; return l; } \
static inline T& operator ^= (T& l, T r) { l = l ^ r; return l; } \
}
} \
static_assert (true, "")
/* Useful for set-operations on small enums.
* For example, for testing "x ∈ {x1, x2, x3}" use:

Loading…
Cancel
Save