From 843730e11be1f05af0a5744ad3dbfe0c73247b61 Mon Sep 17 00:00:00 2001 From: Judah Caruso Date: Fri, 12 Dec 2025 18:34:31 -0700 Subject: [PATCH] just rely on escape analysis --- alloc/allocators.go | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/alloc/allocators.go b/alloc/allocators.go index d1e4498..f233074 100644 --- a/alloc/allocators.go +++ b/alloc/allocators.go @@ -157,11 +157,10 @@ func Nil() Allocator { // Temporary wraps an Allocator, restoring it to its previous state when Reset is called. func Temporary(alloc Allocator) Allocator { - watermark := new(uintptr) - *watermark = Save(alloc) + watermark := Save(alloc) return func(a Action, size, align uintptr, wm *uintptr) (unsafe.Pointer, error) { if a == ActionReset { - Restore(alloc, *watermark) + Restore(alloc, watermark) return nil, nil }