Fix compilation error in speed and size-optimized release builds

This commit is contained in:
kayomn 2023-07-30 14:33:41 +01:00
parent 8cb0f007d5
commit a62588dfe4
1 changed files with 2 additions and 2 deletions

View File

@ -29,7 +29,7 @@ pub const Allocator = struct {
const ErasedActions = struct {
fn deallocate(context: *anyopaque, allocation: []Byte) void {
if (is_zero_aligned) {
return actions.deallocator(@ptrCast(context), allocation);
return actions.deallocate(@ptrCast(context), allocation);
}
return actions.deallocate(@ptrCast(@alignCast(context)), allocation);
@ -37,7 +37,7 @@ pub const Allocator = struct {
fn reallocate(context: *anyopaque, return_address: usize, existing_allocation: ?[]Byte, size: usize) AllocationError![]Byte {
if (is_zero_aligned) {
return actions.reallocator(@ptrCast(context), return_address, existing_allocation, size);
return actions.reallocate(@ptrCast(context), return_address, existing_allocation, size);
}
return actions.reallocate(@ptrCast(@alignCast(context)), return_address, existing_allocation, size);