rust/hg-cpython/src/cindex.rs
changeset 44973 26114bd6ec60
parent 44504 cefd130c98be
child 46412 7d0405e458a0
--- a/rust/hg-cpython/src/cindex.rs	Mon Jun 15 15:14:16 2020 -0400
+++ b/rust/hg-cpython/src/cindex.rs	Mon Jun 15 18:26:40 2020 +0200
@@ -90,10 +90,7 @@
                 ),
             ));
         }
-        Ok(Index {
-            index: index,
-            capi: capi,
-        })
+        Ok(Index { index, capi })
     }
 
     /// return a reference to the CPython Index object in this Struct
@@ -158,7 +155,7 @@
         unsafe { (self.capi.index_length)(self.index.as_ptr()) as usize }
     }
 
-    fn node<'a>(&'a self, rev: Revision) -> Option<&'a Node> {
+    fn node(&self, rev: Revision) -> Option<&Node> {
         let raw = unsafe {
             (self.capi.index_node)(self.index.as_ptr(), rev as c_int)
         };