@@ -195,7 +195,7 @@ impl<T> Env<T> {
195195 }
196196
197197 /// Options and flags which can be used to configure how a [`Database`] is opened.
198- pub fn database_options ( & self ) -> DatabaseOpenOptions < T , Unspecified , Unspecified > {
198+ pub fn database_options ( & self ) -> DatabaseOpenOptions < ' _ , ' _ , T , Unspecified , Unspecified > {
199199 DatabaseOpenOptions :: new ( self )
200200 }
201201
@@ -331,7 +331,7 @@ impl<T> Env<T> {
331331 /// If another write transaction is initiated, while another write transaction exists
332332 /// the thread initiating the new one will wait on a mutex upon completion of the previous
333333 /// transaction.
334- pub fn write_txn ( & self ) -> Result < RwTxn > {
334+ pub fn write_txn ( & self ) -> Result < RwTxn < ' _ > > {
335335 RwTxn :: new ( self )
336336 }
337337
@@ -372,7 +372,7 @@ impl<T> Env<T> {
372372 /// map must be resized
373373 /// * [`crate::MdbError::ReadersFull`]: a read-only transaction was requested, and the reader lock table is
374374 /// full
375- pub fn read_txn ( & self ) -> Result < RoTxn < T > > {
375+ pub fn read_txn ( & self ) -> Result < RoTxn < ' _ , T > > {
376376 RoTxn :: new ( self )
377377 }
378378
@@ -594,7 +594,7 @@ impl<T> Env<T> {
594594 /// it is okay to call `mdb_env_set_mapsize` for an open environment as long as no transactions are active,
595595 /// but the library does not check for this condition, so the caller must ensure it explicitly.
596596 pub unsafe fn resize ( & self , new_size : usize ) -> Result < ( ) > {
597- if new_size % page_size:: get ( ) != 0 {
597+ if ! new_size. is_multiple_of ( page_size:: get ( ) ) {
598598 let msg = format ! (
599599 "map size ({}) must be a multiple of the system page size ({})" ,
600600 new_size,
0 commit comments