chiark / gitweb /
wip errors from introducing accounts
authorIan Jackson <ijackson@chiark.greenend.org.uk>
Sun, 1 Nov 2020 21:48:10 +0000 (21:48 +0000)
committerIan Jackson <ijackson@chiark.greenend.org.uk>
Sun, 1 Nov 2020 21:48:10 +0000 (21:48 +0000)
Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
src/global.rs

index b729ccc3b09c232ea71ba1e1ac649f946cd20eee..a544705d72421211420e1aca087e88bbbb50c7d9 100644 (file)
@@ -273,8 +273,8 @@ impl InstanceRef {
 
 impl<A> Unauthorised<InstanceRef, A> {
   #[throws(InstanceLockError)]
-  pub fn lock(&self) -> Unauthorised<InstanceGuard<'_>, A> {
-    let must_not_escape = self.by(Authorisation::authorise_any());
+  pub fn lock<'r>(&'r self) -> Unauthorised<InstanceGuard<'r>, A> {
+    let must_not_escape = self.by_ref(Authorisation::authorise_any());
     Unauthorised::of(must_not_escape.lock()?)
   }
 }