Functions `a` and `b` are unused. Silence the lint.

This commit is contained in:
amab8901 2022-10-21 16:49:31 +02:00 committed by GitHub
parent 81c03c260f
commit 541196de37
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 0 deletions

View File

@ -533,10 +533,12 @@ The type system prevents us from moving the data.
> # this.b = self_ptr;
> # }
> #
> # #[allow(unused)]
> # fn a<'a>(self: Pin<&'a Self>) -> &'a str {
> # &self.get_ref().a
> # }
> #
> # #[allow(unused)]
> # fn b<'a>(self: Pin<&'a Self>) -> &'a String {
> # assert!(!self.b.is_null(), "Test::b called without Test::init being called first");
> # unsafe { &*(self.b) }