mirror of
https://github.com/Ed94/Odin.git
synced 2026-08-05 15:18:49 +00:00
Update total_used for arena_static_reset_to
This commit is contained in:
@@ -96,8 +96,10 @@ arena_static_reset_to :: proc(arena: ^Arena, pos: uint, loc := #caller_location)
|
|||||||
if prev_pos < pos {
|
if prev_pos < pos {
|
||||||
mem.zero_slice(arena.curr_block.base[arena.curr_block.used:][:pos-prev_pos])
|
mem.zero_slice(arena.curr_block.base[arena.curr_block.used:][:pos-prev_pos])
|
||||||
}
|
}
|
||||||
|
arena.total_used = arena.curr_block.used
|
||||||
return true
|
return true
|
||||||
} else if pos == 0 {
|
} else if pos == 0 {
|
||||||
|
arena.total_used = 0
|
||||||
return true
|
return true
|
||||||
}
|
}
|
||||||
return false
|
return false
|
||||||
|
|||||||
Reference in New Issue
Block a user