summary refs log tree commit diff stats
path: root/lib/system/alloc.nim
diff options
context:
space:
mode:
Diffstat (limited to 'lib/system/alloc.nim')
-rwxr-xr-xlib/system/alloc.nim3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/system/alloc.nim b/lib/system/alloc.nim
index 55e1c26a7..7b52780fe 100755
--- a/lib/system/alloc.nim
+++ b/lib/system/alloc.nim
@@ -319,7 +319,8 @@ iterator allObjects(m: TMemRegion): pointer {.inline.} =
         
         let size = c.size
         var a = cast[TAddress](addr(c.data))
-        while a <% c.acc:
+        let limit = a + c.acc
+        while a <% limit:
           yield cast[pointer](a)
           a = a +% size
       else:
ion' href='/ahoang/Nim/blame/security.md?h=devel&id=a65189a739c59fcc0d7b3f8fdcb2cf8bed432f68'>^
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20