| ... | @@ -915,6 +915,10 @@ pub fn testAllocator(base_allocator: *mem.Allocator) !void { | ... | @@ -915,6 +915,10 @@ pub fn testAllocator(base_allocator: *mem.Allocator) !void { |
| 915 | testing.expect(slice.len == 10); | 915 | testing.expect(slice.len == 10); |
| 916 | | 916 | |
| 917 | allocator.free(slice); | 917 | allocator.free(slice); |
| | 918 | |
| | 919 | const zero_bit_ptr = try allocator.create(u0); |
| | 920 | zero_bit_ptr.* = 0; |
| | 921 | allocator.destroy(zero_bit_ptr); |
| 918 | } | 922 | } |
| 919 | | 923 | |
| 920 | pub fn testAllocatorAligned(base_allocator: *mem.Allocator, comptime alignment: u29) !void { | 924 | pub fn testAllocatorAligned(base_allocator: *mem.Allocator, comptime alignment: u29) !void { |