interpret: rename Pointer::from_addr → from_addr_invalid
This commit is contained in:
parent
2d91939bb7
commit
91d25168cd
5 changed files with 8 additions and 6 deletions
|
@ -251,14 +251,16 @@ impl<Prov> Pointer<Option<Prov>> {
|
|||
}
|
||||
|
||||
impl<Prov> Pointer<Option<Prov>> {
|
||||
/// Creates a pointer to the given address, with invalid provenance (i.e., cannot be used for
|
||||
/// any memory access).
|
||||
#[inline(always)]
|
||||
pub fn from_addr(addr: u64) -> Self {
|
||||
pub fn from_addr_invalid(addr: u64) -> Self {
|
||||
Pointer { provenance: None, offset: Size::from_bytes(addr) }
|
||||
}
|
||||
|
||||
#[inline(always)]
|
||||
pub fn null() -> Self {
|
||||
Pointer::from_addr(0)
|
||||
Pointer::from_addr_invalid(0)
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue