Closed MarcoCicognani closed 3 years ago
Thanks!
Heap
still contains thesize
and theused
counters, so it is stillHeap
that usesalign_layout
. Tell me if this is not the best solution
I would prefer to move the align_layout
calls to HoleList::allocate_first_fit
and HoleList::deallocate
. Maybe we could use a &mut Layout
reference as argument, which is then adjusted. Alternatively, we could also return the adjusted Layout
as a second return type. What do you think?
I think that is a good idea. I implement it immediately
But size
and used
must remain into Heap
, right?
Yes, I would keep them in Heap
, to keep the HoleList
as simple as possible.
Well, done!
Done
Published as v0.8.10
Hi Phil!
I've made hole.rs public for external uses and moved
align_layout()
function intoHoleList
.Heap
still contains thesize
and theused
counters, so it is stillHeap
that usesalign_layout
. Tell me if this is not the best solution