diff --git a/src/hb-bit-set-invertible.hh b/src/hb-bit-set-invertible.hh index caea47d8d..512107ffd 100644 --- a/src/hb-bit-set-invertible.hh +++ b/src/hb-bit-set-invertible.hh @@ -100,7 +100,7 @@ struct hb_bit_set_invertible_t void add (hb_codepoint_t g) { unlikely (inverted) ? s.del (g) : s.add (g); } bool add_range (hb_codepoint_t a, hb_codepoint_t b) - { return unlikely (inverted) ? (s.del_range (a, b), true) : s.add_range (a, b); } + { return unlikely (inverted) ? ((void) s.del_range (a, b), true) : s.add_range (a, b); } template void add_array (const T *array, unsigned int count, unsigned int stride=sizeof(T)) diff --git a/src/hb-coretext.cc b/src/hb-coretext.cc index 6ccc1b0a2..2e221cbd1 100644 --- a/src/hb-coretext.cc +++ b/src/hb-coretext.cc @@ -1151,7 +1151,7 @@ resize_and_retry: pos->x_offset = info->var1.i32; pos->y_offset = info->var2.i32; - info++, pos++; + info++; pos++; } else for (unsigned int i = 0; i < count; i++) @@ -1160,7 +1160,7 @@ resize_and_retry: pos->x_offset = info->var1.i32; pos->y_offset = info->var2.i32; - info++, pos++; + info++; pos++; } /* Fix up clusters so that we never return out-of-order indices; diff --git a/src/hb-ot-var-fvar-table.hh b/src/hb-ot-var-fvar-table.hh index e06655868..c5c476bc0 100644 --- a/src/hb-ot-var-fvar-table.hh +++ b/src/hb-ot-var-fvar-table.hh @@ -213,7 +213,7 @@ struct fvar if (!axis_index) axis_index = &i; *axis_index = HB_OT_VAR_NO_AXIS_INDEX; auto axes = get_axes (); - return axes.lfind (tag, axis_index) && (axes[*axis_index].get_axis_deprecated (info), true); + return axes.lfind (tag, axis_index) && ((void) axes[*axis_index].get_axis_deprecated (info), true); } #endif bool @@ -221,7 +221,7 @@ struct fvar { unsigned i; auto axes = get_axes (); - return axes.lfind (tag, &i) && (axes[i].get_axis_info (i, info), true); + return axes.lfind (tag, &i) && ((void) axes[i].get_axis_info (i, info), true); } int normalize_axis_value (unsigned int axis_index, float v) const diff --git a/src/hb-repacker.hh b/src/hb-repacker.hh index c9075fa1e..19c2c2f34 100644 --- a/src/hb-repacker.hh +++ b/src/hb-repacker.hh @@ -760,7 +760,7 @@ struct graph_t } bool check_success (bool success) - { return this->successful && (success || (err_other_error (), false)); } + { return this->successful && (success || ((void) err_other_error (), false)); } /* * Creates a map from objid to # of incoming edges. diff --git a/src/hb-subset.cc b/src/hb-subset.cc index de29f8ce1..428a9dd12 100644 --- a/src/hb-subset.cc +++ b/src/hb-subset.cc @@ -336,7 +336,7 @@ _is_table_present (hb_face_t *source, hb_tag_t tag) hb_tag_t table_tags[32]; unsigned offset = 0, num_tables = ARRAY_LENGTH (table_tags); - while ((hb_face_get_table_tags (source, offset, &num_tables, table_tags), num_tables)) + while (((void) hb_face_get_table_tags (source, offset, &num_tables, table_tags), num_tables)) { for (unsigned i = 0; i < num_tables; ++i) if (table_tags[i] == tag) @@ -499,7 +499,7 @@ hb_subset_plan_execute_or_fail (hb_subset_plan_t *plan) hb_vector_t buf; buf.alloc (4096 - 16); - while ((_get_table_tags (plan, offset, &num_tables, table_tags), num_tables)) + while (((void) _get_table_tags (plan, offset, &num_tables, table_tags), num_tables)) { for (unsigned i = 0; i < num_tables; ++i) { diff --git a/src/hb.hh b/src/hb.hh index 14872e2a4..d574f0881 100644 --- a/src/hb.hh +++ b/src/hb.hh @@ -64,6 +64,7 @@ #pragma GCC diagnostic error "-Wbitwise-instead-of-logical" #pragma GCC diagnostic error "-Wcast-align" #pragma GCC diagnostic error "-Wcast-function-type" +#pragma GCC diagnostic error "-Wcomma" #pragma GCC diagnostic error "-Wdelete-non-virtual-dtor" #pragma GCC diagnostic error "-Wembedded-directive" #pragma GCC diagnostic error "-Wextra-semi-stmt"