summaryrefslogtreecommitdiff
path: root/rust/src/linearview.rs
diff options
context:
space:
mode:
authorRubens Brandao <git@rubens.io>2024-05-03 13:28:53 -0300
committerKyle Martin <krm504@nyu.edu>2024-05-10 12:00:27 -0400
commitea7a22b16fc56c23af397dd690c6c839dfb3a8f1 (patch)
tree45f3ba19172017694388ab6f7266e23df76bb670 /rust/src/linearview.rs
parent015314d34d073a8ebbd958edf8150a81381f12c2 (diff)
hide array implementation details
Diffstat (limited to 'rust/src/linearview.rs')
-rw-r--r--rust/src/linearview.rs8
1 files changed, 2 insertions, 6 deletions
diff --git a/rust/src/linearview.rs b/rust/src/linearview.rs
index 31b05ad2..84b4323e 100644
--- a/rust/src/linearview.rs
+++ b/rust/src/linearview.rs
@@ -415,17 +415,13 @@ impl std::fmt::Display for LinearDisassemblyLine {
impl CoreArrayProvider for LinearDisassemblyLine {
type Raw = BNLinearDisassemblyLine;
type Context = ();
+ type Wrapped<'a> = Guard<'a, LinearDisassemblyLine>;
}
-unsafe impl CoreOwnedArrayProvider for LinearDisassemblyLine {
+unsafe impl CoreArrayProviderInner for LinearDisassemblyLine {
unsafe fn free(raw: *mut BNLinearDisassemblyLine, count: usize, _context: &()) {
BNFreeLinearDisassemblyLines(raw, count);
}
-}
-
-unsafe impl CoreArrayWrapper for LinearDisassemblyLine {
- type Wrapped<'a> = Guard<'a, LinearDisassemblyLine>;
-
unsafe fn wrap_raw<'a>(raw: &'a Self::Raw, _context: &'a Self::Context) -> Self::Wrapped<'a> {
Guard::new(LinearDisassemblyLine::from_raw(raw), _context)
}