summaryrefslogtreecommitdiff
path: root/rust/src/low_level_il/function.rs
diff options
context:
space:
mode:
authorJosh Ferrell <josh@vector35.com>2025-09-29 14:53:05 -0400
committerJosh Ferrell <josh@vector35.com>2025-09-29 15:08:06 -0400
commitfd5a89e174e01b0adb089dcf8f6da36cf5008443 (patch)
tree25f66fa722f8759a817a053580f2461309ac448e /rust/src/low_level_il/function.rs
parent4870c90e6fbf31898c57db04f97c69f647157fd5 (diff)
Fix rust warnings about lifetimes introduced by 1.89.0
Diffstat (limited to 'rust/src/low_level_il/function.rs')
-rw-r--r--rust/src/low_level_il/function.rs14
1 files changed, 7 insertions, 7 deletions
diff --git a/rust/src/low_level_il/function.rs b/rust/src/low_level_il/function.rs
index ca6508c9..6d2e4239 100644
--- a/rust/src/low_level_il/function.rs
+++ b/rust/src/low_level_il/function.rs
@@ -95,7 +95,7 @@ where
}
}
- pub fn instruction_at<L: Into<Location>>(&self, loc: L) -> Option<LowLevelILInstruction<M, F>> {
+ pub fn instruction_at<L: Into<Location>>(&self, loc: L) -> Option<LowLevelILInstruction<'_, M, F>> {
Some(LowLevelILInstruction::new(
self,
self.instruction_index_at(loc)?,
@@ -103,7 +103,7 @@ where
}
/// Get all the instructions for a given location.
- pub fn instructions_at<L: Into<Location>>(&self, loc: L) -> Vec<LowLevelILInstruction<M, F>> {
+ pub fn instructions_at<L: Into<Location>>(&self, loc: L) -> Vec<LowLevelILInstruction<'_, M, F>> {
let loc = loc.into();
self.instruction_indexes_at(loc)
.iter()
@@ -146,7 +146,7 @@ where
pub fn instruction_from_index(
&self,
index: LowLevelInstructionIndex,
- ) -> Option<LowLevelILInstruction<M, F>> {
+ ) -> Option<LowLevelILInstruction<'_, M, F>> {
if index.0 >= self.instruction_count() {
None
} else {
@@ -178,7 +178,7 @@ where
}
}
- pub fn basic_blocks(&self) -> Array<BasicBlock<LowLevelILBlock<M, F>>> {
+ pub fn basic_blocks(&self) -> Array<BasicBlock<LowLevelILBlock<'_, M, F>>> {
use binaryninjacore_sys::BNGetLowLevelILBasicBlockList;
unsafe {
@@ -195,7 +195,7 @@ where
pub fn basic_block_containing_index(
&self,
index: LowLevelInstructionIndex,
- ) -> Option<Ref<BasicBlock<LowLevelILBlock<M, F>>>> {
+ ) -> Option<Ref<BasicBlock<LowLevelILBlock<'_, M, F>>>> {
let block = unsafe { BNGetLowLevelILBasicBlockForInstruction(self.handle, index.0) };
if block.is_null() {
None
@@ -259,7 +259,7 @@ impl<M: FunctionMutability> LowLevelILFunction<M, SSA> {
pub fn get_ssa_register_uses<R: ArchReg>(
&self,
reg: LowLevelILSSARegisterKind<R>,
- ) -> Vec<LowLevelILInstruction<M, SSA>> {
+ ) -> Vec<LowLevelILInstruction<'_, M, SSA>> {
use binaryninjacore_sys::BNGetLowLevelILSSARegisterUses;
let register_id = match reg {
LowLevelILSSARegisterKind::Full { kind, .. } => kind.id(),
@@ -287,7 +287,7 @@ impl<M: FunctionMutability> LowLevelILFunction<M, SSA> {
pub fn get_ssa_register_definition<R: ArchReg>(
&self,
reg: &LowLevelILSSARegisterKind<R>,
- ) -> Option<LowLevelILInstruction<M, SSA>> {
+ ) -> Option<LowLevelILInstruction<'_, M, SSA>> {
use binaryninjacore_sys::BNGetLowLevelILSSARegisterDefinition;
let register_id = match reg {
LowLevelILSSARegisterKind::Full { kind, .. } => kind.id(),