summaryrefslogtreecommitdiff
path: root/rust/src/variable.rs
diff options
context:
space:
mode:
Diffstat (limited to 'rust/src/variable.rs')
-rw-r--r--rust/src/variable.rs55
1 files changed, 0 insertions, 55 deletions
diff --git a/rust/src/variable.rs b/rust/src/variable.rs
index fc6febfb..d224a45b 100644
--- a/rust/src/variable.rs
+++ b/rust/src/variable.rs
@@ -911,58 +911,3 @@ impl PossibleValueSet {
}
}
}
-
-#[derive(Debug, Copy, Clone, Hash, PartialEq, Eq)]
-pub struct IndirectBranchInfo {
- pub source: Location,
- pub dest: Location,
- pub auto_defined: bool,
-}
-
-impl From<BNIndirectBranchInfo> for IndirectBranchInfo {
- fn from(value: BNIndirectBranchInfo) -> Self {
- Self {
- source: Location::from_raw(value.sourceAddr, value.sourceArch),
- dest: Location::from_raw(value.destAddr, value.destArch),
- auto_defined: value.autoDefined,
- }
- }
-}
-
-impl From<IndirectBranchInfo> for BNIndirectBranchInfo {
- fn from(value: IndirectBranchInfo) -> Self {
- let source_arch = value
- .source
- .arch
- .map(|a| a.handle)
- .unwrap_or(std::ptr::null_mut());
- let dest_arch = value
- .source
- .arch
- .map(|a| a.handle)
- .unwrap_or(std::ptr::null_mut());
- Self {
- sourceArch: source_arch,
- sourceAddr: value.source.addr,
- destArch: dest_arch,
- destAddr: value.dest.addr,
- autoDefined: value.auto_defined,
- }
- }
-}
-
-impl CoreArrayProvider for IndirectBranchInfo {
- type Raw = BNIndirectBranchInfo;
- type Context = ();
- type Wrapped<'a> = Self;
-}
-
-unsafe impl CoreArrayProviderInner for IndirectBranchInfo {
- unsafe fn free(raw: *mut Self::Raw, _count: usize, _context: &Self::Context) {
- BNFreeIndirectBranchList(raw)
- }
-
- unsafe fn wrap_raw<'a>(raw: &'a Self::Raw, _context: &'a Self::Context) -> Self::Wrapped<'a> {
- Self::from(*raw)
- }
-}