@@ -113,7 +113,7 @@ impl Tree {
113113 & bbn_freelist_tracked,
114114 bbn_bump,
115115 )
116- . with_context ( || format ! ( "failed to reconstruct btree from bbn store file" ) ) ?;
116+ . context ( "failed to reconstruct btree from bbn store file" ) ?;
117117 let shared = Shared {
118118 io_handle : io_pool. make_handle ( ) ,
119119 page_pool : io_pool. page_pool ( ) . clone ( ) ,
@@ -386,7 +386,7 @@ pub fn create(db_dir: impl AsRef<Path>) -> anyhow::Result<()> {
386386 ln_fd. set_len ( BRANCH_NODE_SIZE as u64 ) ?;
387387 bbn_fd. set_len ( BRANCH_NODE_SIZE as u64 ) ?;
388388
389- // Sync files and the directory. I am not sure if syncing files is necessar , but it
389+ // Sync files and the directory. I am not sure if syncing files is necessary , but it
390390 // is necessary to make sure that the directory is synced.
391391 ln_fd. sync_all ( ) ?;
392392 bbn_fd. sync_all ( ) ?;
@@ -694,17 +694,17 @@ impl AsyncLookup {
694694 meta : Option < OverflowPageInfo > ,
695695 ) -> Option < Option < Vec < u8 > > > {
696696 match self . state {
697- AsyncLookupState :: Done => return None ,
697+ AsyncLookupState :: Done => None ,
698698 AsyncLookupState :: Initial ( ref inner) => {
699699 let leaf = inner. finish_inner ( page) ;
700700 match ops:: finish_lookup_async ( self . key , & leaf, & inner. read_tx . leaf_store ) {
701701 Ok ( val) => {
702702 self . state = AsyncLookupState :: Done ;
703- return Some ( val) ;
703+ Some ( val)
704704 }
705705 Err ( overflow) => {
706706 self . state = AsyncLookupState :: Overflow ( overflow, None ) ;
707- return None ;
707+ None
708708 }
709709 }
710710 }
0 commit comments