Skip to content

Commit 2403e72

Browse files
committed
[Rust] Misc things for WARP
- Make LowLevelILFunction::from_raw public" - Add a helper to get lifted il from flow graph
1 parent 2c71ed7 commit 2403e72

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

rust/src/flowgraph.rs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -124,6 +124,10 @@ impl FlowGraph {
124124
unsafe { BNSetViewForFlowGraph(self.handle, view_ptr) }
125125
}
126126

127+
pub fn lifted_il(&self) -> Option<Ref<LowLevelILRegularFunction>> {
128+
self.function()?.lifted_il().ok()
129+
}
130+
127131
pub fn low_level_il(&self) -> Option<Ref<LowLevelILRegularFunction>> {
128132
unsafe {
129133
let llil_ptr = BNGetFlowGraphLowLevelILFunction(self.handle);

rust/src/low_level_il/function.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ where
7070
}
7171
}
7272

73-
pub(crate) unsafe fn from_raw(handle: *mut BNLowLevelILFunction) -> Self {
73+
pub unsafe fn from_raw(handle: *mut BNLowLevelILFunction) -> Self {
7474
Self::from_raw_with_arch(handle, None)
7575
}
7676

0 commit comments

Comments
 (0)