From 59a94943aa2f19dd87076c79410c9ecaf626821c Mon Sep 17 00:00:00 2001 From: Thomas Harte Date: Thu, 13 Jun 2019 10:55:29 -0400 Subject: [PATCH] Resolves final set of build warnings. --- .../68000/Implementation/68000Implementation.hpp | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/Processors/68000/Implementation/68000Implementation.hpp b/Processors/68000/Implementation/68000Implementation.hpp index 1d4e180b8..cfad42334 100644 --- a/Processors/68000/Implementation/68000Implementation.hpp +++ b/Processors/68000/Implementation/68000Implementation.hpp @@ -1569,7 +1569,7 @@ template void Proces } else { \ destination = decltype(destination)(\ (value >> shift_count) | \ - ((value & (1 << (size - 1)) ? 0xffffffff : 0x000000000) << (size - shift_count)) \ + ((value & decltype(value)(1 << (size - 1)) ? 0xffffffff : 0x000000000) << (size - shift_count)) \ ); \ extend_flag_ = carry_flag_ = decltype(carry_flag_)(value) & decltype(carry_flag_)(1 << (shift_count - 1)); \ } \ @@ -1704,7 +1704,7 @@ template void Proces destination = decltype(destination)(\ (value << shift_count) | \ (value >> (size + 1 - shift_count)) | \ - ((extend_flag_ ? (1 << (size - 1)) : 0) >> (size - shift_count))\ + ((extend_flag_ ? decltype(destination)(1 << (size - 1)) : 0) >> (size - shift_count))\ ); \ carry_flag_ = extend_flag_ = (value >> (size - shift_count))&1; \ } \ @@ -1731,11 +1731,10 @@ template void Proces carry_flag_ = extend_flag_; \ } else { \ shift_count %= (size + 1); \ - destination = decltype(destination)(\ - (value >> shift_count) | \ - (value << (size + 1 - shift_count)) | \ - ((extend_flag_ ? 1 : 0) << (size - shift_count)) \ - ); \ + destination = \ + decltype(destination)(value >> shift_count) | \ + decltype(destination)(value << (size + 1 - shift_count)) | \ + decltype(destination)((extend_flag_ ? 1 : 0) << (size - shift_count)); \ carry_flag_ = extend_flag_ = value & (1 << shift_count); \ } \ \