From 4587b465d428ac3944192226bff48a2808fc34cf Mon Sep 17 00:00:00 2001 From: Nik Date: Thu, 13 Jul 2023 12:08:25 +0200 Subject: [PATCH] includes/std: Fixed std::mem::eof() not working correctly with non-zero base addresses --- includes/std/mem.pat | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/std/mem.pat b/includes/std/mem.pat index 00546e4..e926785 100644 --- a/includes/std/mem.pat +++ b/includes/std/mem.pat @@ -46,7 +46,7 @@ namespace std::mem { @return True if the cursor is at the end of the memory */ fn eof() { - return $ >= std::mem::size(); + return $ >= (std::mem::base_address() + std::mem::size()); }; /**