NFC: Introduce and switch to pal_zero
This wrapper will allow us to pass `AuthPtr<T,B> p` to zero() without needing to write `p.unsafe_auth_ptr` to get to a `T*` inside. Moreover, it will give us a convenient point to assert that `B` is such that the pointer can be used to manipulate the memory map (i.e. is not exported).
This commit is contained in:
committed by
Nathaniel Wesley Filardo
parent
4cfcf344fc
commit
7f841ff081
@@ -94,7 +94,7 @@ namespace snmalloc
|
||||
self->free--;
|
||||
|
||||
if constexpr (zero_mem == YesZero)
|
||||
PAL::zero(p, size);
|
||||
pal_zero<PAL>(p, size);
|
||||
else
|
||||
UNUSED(size);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user