We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 9492d65 commit 05d5676Copy full SHA for 05d5676
src/module.rs
@@ -37,13 +37,19 @@ impl ModuleTag {
37
pub fn end_address(&self) -> u32 {
38
self.mod_end
39
}
40
+
41
+ /// The size of the module/the BLOB in memory.
42
+ pub fn module_size(&self) -> u32 {
43
+ self.mod_end - self.mod_start
44
+ }
45
46
47
impl Debug for ModuleTag {
48
fn fmt(&self, f: &mut Formatter<'_>) -> core::fmt::Result {
49
f.debug_struct("ModuleTag")
50
.field("type", &self.typ)
- .field("size", &self.size)
51
+ .field("size (tag)", &self.size)
52
+ .field("size (module)", &(self.module_size()))
53
.field("mod_start", &(self.mod_start as *const usize))
54
.field("mod_end", &(self.mod_end as *const usize))
55
.field("cmdline", &self.cmdline())
0 commit comments