| author | |
| committer | |
| log | d68ae35c1153c6263292d60e4f5f6b828d7c8e8f |
| tree | 12a2d5c18b20fa33ea5f403d6e2c9f85b5914a77 |
| parent | da7880b4cf1b909c68aed2d1f6c702cca0807ee8 |
| signature |
1 files changed, 4 insertions(+), 0 deletions(-)
std/heap.zig+4| ... | ... | @@ -273,6 +273,10 @@ pub const FixedBufferAllocator = struct { |
| 273 | 273 | buffer: []u8, |
| 274 | 274 | |
| 275 | 275 | pub fn init(buffer: []u8) FixedBufferAllocator { |
| 276 | // This loop gets optimized out in ReleaseFast mode | |
| 277 | for (buffer) |*byte| { | |
| 278 | byte.* = undefined; | |
| 279 | } | |
| 276 | 280 | return FixedBufferAllocator{ |
| 277 | 281 | .allocator = Allocator{ |
| 278 | 282 | .allocFn = alloc, |