From 6ad58028669be32e7b6f4dd718b970044605ca08 Mon Sep 17 00:00:00 2001 From: folkert van heusden Date: Sat, 25 Mar 2023 10:33:32 +0100 Subject: [PATCH] operator precedence warning from compiler --- bus.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bus.cpp b/bus.cpp index 43a81ee..9fa201e 100644 --- a/bus.cpp +++ b/bus.cpp @@ -501,7 +501,7 @@ uint32_t bus::calculate_physical_address(const int run_mode, const uint16_t a, c if ((MMR0 & 1) || (is_write && (MMR0 & (1 << 8)))) { const uint8_t apf = a >> 13; // active page field - bool d = space == d_space & (!!(MMR3 & di_ena_mask[run_mode])) ? space == d_space : false; + bool d = (space == d_space) & ((!!(MMR3 & di_ena_mask[run_mode])) ? space == d_space : false); uint16_t p_offset = a & 8191; // page offset