From 386f572e9a8e53a4b60c23b89b062e386ae48b97 Mon Sep 17 00:00:00 2001 From: Thomas Harte Date: Thu, 4 Jan 2024 11:11:26 -0500 Subject: [PATCH] Add assert. --- Machines/Apple/AppleIIgs/MemoryMap.hpp | 1 + 1 file changed, 1 insertion(+) diff --git a/Machines/Apple/AppleIIgs/MemoryMap.hpp b/Machines/Apple/AppleIIgs/MemoryMap.hpp index 866952d7c..92033f339 100644 --- a/Machines/Apple/AppleIIgs/MemoryMap.hpp +++ b/Machines/Apple/AppleIIgs/MemoryMap.hpp @@ -71,6 +71,7 @@ class MemoryMap { bool is_shadowed(const Region ®ion, uint32_t address) const { const auto physical = physical_address(region, address); + assert(physical >= 0 && physical <= 0xff'ffff); return shadow_pages_[(physical >> 10) & 127] & shadow_banks_[physical >> 17]; } void write(const Region ®ion, uint32_t address, uint8_t value) {