Open nuta opened 2 years ago
In #141, I noticed that we need to track the lifetime of a PAddr object which references to OwnedPages. It's problematic because it lead to memory leaks or nasty use-after-free bugs. In this issue, I'll replace PAddr and VAddr as:
PAddr
OwnedPages
VAddr
#[repr(transparent)] pub struct PAddr<'a> { value: usize, _pd: PhantomData<&'a ()>, }
In #141, I noticed that we need to track the lifetime of a
PAddr
object which references toOwnedPages
. It's problematic because it lead to memory leaks or nasty use-after-free bugs. In this issue, I'll replacePAddr
andVAddr
as: