macro_rules! pa_range {
($range:expr) => { ... };
}
Expand description
Converts the given range expression into PhysAddrRange
. Panics if the
range is invalid.
§Example
use memory_addr::pa_range;
let range = pa_range!(0x1000..0x2000);
assert_eq!(range.start, 0x1000.into());
assert_eq!(range.end, 0x2000.into());
And this will panic:
ⓘ
let _ = pa_range!(0x2000..0x1000);