From 32197bdcd7fe5268355a0449e0e05fe059c6d953 Mon Sep 17 00:00:00 2001 From: Norbert Nopper Date: Wed, 13 Jan 2016 10:35:44 +0100 Subject: [PATCH] Fix, that spirv-tools did not build, as two casts are not present. --- include/util/hex_float.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/include/util/hex_float.h b/include/util/hex_float.h index 183b64adb..2241b999a 100644 --- a/include/util/hex_float.h +++ b/include/util/hex_float.h @@ -842,9 +842,9 @@ std::istream& operator>>(std::istream& is, HexFloat& value) { // If we are here the bits represented belong in the fractional // part of the float, and we have to adjust the exponent accordingly. fraction = - fraction | + static_cast(fraction | static_cast( - write_bit << (HF::top_bit_left_shift - fraction_index++)); + write_bit << (HF::top_bit_left_shift - fraction_index++))); exponent = static_cast(exponent + 1); } bits_written |= write_bit != 0; @@ -874,9 +874,9 @@ std::istream& operator>>(std::istream& is, HexFloat& value) { exponent = static_cast(exponent - 1); } else { fraction = - fraction | + static_cast(fraction | static_cast( - write_bit << (HF::top_bit_left_shift - fraction_index++)); + write_bit << (HF::top_bit_left_shift - fraction_index++))); } } } else {