Skip to content

Commit

Permalink
Fix some warnings about elided lifetimes
Browse files Browse the repository at this point in the history
these popped up on the latest rustc

Signed-off-by: Kent Overstreet <[email protected]>
  • Loading branch information
Kent Overstreet committed Oct 12, 2024
1 parent 10857a2 commit f0bfa49
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion bch_bindgen/src/bkey.rs
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ impl<'a, 'b> BkeySC<'a> {
BkeySCToText { k: self, fs }
}

pub fn v(&'a self) -> BkeyValC {
pub fn v(&'a self) -> BkeyValC<'a> {
unsafe {
let ty: c::bch_bkey_type = transmute(self.k.type_ as u32);

Expand Down
6 changes: 3 additions & 3 deletions bch_bindgen/src/btree.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ pub struct BtreeTrans<'f> {
}

impl<'f> BtreeTrans<'f> {
pub fn new(fs: &'f Fs) -> BtreeTrans {
pub fn new(fs: &'f Fs) -> BtreeTrans<'f> {
unsafe {
BtreeTrans {
raw: &mut *c::__bch2_trans_get(fs.raw, 0),
Expand Down Expand Up @@ -81,7 +81,7 @@ impl<'t> BtreeIter<'t> {
}
}

pub fn peek_upto<'i>(&'i mut self, end: c::bpos) -> Result<Option<BkeySC>, bch_errcode> {
pub fn peek_upto<'i>(&'i mut self, end: c::bpos) -> Result<Option<BkeySC<'i>>, bch_errcode> {
unsafe {
let k = c::bch2_btree_iter_peek_upto(&mut self.raw, end);
errptr_to_result_c(k.k).map(|_| {
Expand Down Expand Up @@ -146,7 +146,7 @@ impl<'t> BtreeNodeIter<'t> {
locks_want: u32,
depth: u32,
flags: BtreeIterFlags,
) -> BtreeNodeIter {
) -> BtreeNodeIter<'t> {
unsafe {
let mut iter: MaybeUninit<c::btree_iter> = MaybeUninit::uninit();
c::bch2_trans_node_iter_init(
Expand Down

0 comments on commit f0bfa49

Please sign in to comment.