diff --git a/src/hb-ot-var-fvar-table.hh b/src/hb-ot-var-fvar-table.hh index 3565185fd..c73348ef4 100644 --- a/src/hb-ot-var-fvar-table.hh +++ b/src/hb-ot-var-fvar-table.hh @@ -120,10 +120,10 @@ struct fvar const AxisRecord &axis = get_axes ()[axis_index]; info->tag = axis.axisTag; info->name_id = axis.axisNameID; - info->default_value = axis.defaultValue / 65536.; + info->default_value = axis.defaultValue / 65536.f; /* Ensure order, to simplify client math. */ - info->min_value = hb_min (info->default_value, axis.minValue / 65536.); - info->max_value = hb_max (info->default_value, axis.maxValue / 65536.); + info->min_value = hb_min (info->default_value, axis.minValue / 65536.f); + info->max_value = hb_max (info->default_value, axis.maxValue / 65536.f); } void get_axis_info (unsigned int axis_index, @@ -134,10 +134,10 @@ struct fvar info->tag = axis.axisTag; info->name_id = axis.axisNameID; info->flags = (hb_ot_var_axis_flags_t) (unsigned int) axis.flags; - info->default_value = axis.defaultValue / 65536.; + info->default_value = axis.defaultValue / 65536.f; /* Ensure order, to simplify client math. */ - info->min_value = hb_min (info->default_value, axis.minValue / 65536.); - info->max_value = hb_max (info->default_value, axis.maxValue / 65536.); + info->min_value = hb_min (info->default_value, axis.minValue / 65536.f); + info->max_value = hb_max (info->default_value, axis.maxValue / 65536.f); info->reserved = 0; } diff --git a/src/hb.hh b/src/hb.hh index 96db1f9d4..3d4b18033 100644 --- a/src/hb.hh +++ b/src/hb.hh @@ -65,6 +65,7 @@ #pragma GCC diagnostic error "-Wcast-align" #pragma GCC diagnostic error "-Wcast-function-type" #pragma GCC diagnostic error "-Wdelete-non-virtual-dtor" +#pragma GCC diagnostic error "-Wdouble-promotion" #pragma GCC diagnostic error "-Wformat-security" #pragma GCC diagnostic error "-Wimplicit-function-declaration" #pragma GCC diagnostic error "-Winit-self"