solitaire: Implement Keyed for Mut<T: Keyed>

Change-Id: I6680315db9ac2fe913a85b01b471572047cbe658
This commit is contained in:
Stan Drozd 2021-08-24 15:52:39 +02:00 committed by Stanislaw Drozd
parent 63b77714ec
commit 5f52dc6d76
1 changed files with 10 additions and 0 deletions

View File

@ -9,6 +9,7 @@ use crate::{
Data,
Derive,
Info,
Mut,
Signer,
System,
Sysvar,
@ -59,6 +60,15 @@ where
}
}
impl<'a, 'b: 'a, T> Keyed<'a, 'b> for Mut<T>
where
T: Keyed<'a, 'b>,
{
fn info(&'a self) -> &'a Info<'b> {
self.0.info()
}
}
impl<'a, 'b: 'a> Keyed<'a, 'b> for Info<'b> {
fn info(&'a self) -> &'a Info<'b> {
self