I think I have solved the lifetime issue.

OwnedBreadcrumbTreeElement's needed a lifetime associated with them because IntoContextElement had lifetimes associated with it.
This commit is contained in:
Tom Alexander
2020-06-06 17:52:46 -04:00
parent adbc236836
commit e725728a65
2 changed files with 5 additions and 12 deletions

View File

@@ -13,7 +13,7 @@ pub enum BreadcrumbTreeElement<'a> {
// the same BreadcrumbTreeElement but a different parent (for
// example, when inserting behind the tail), we don't need to the
// copy the already owned/malloc'd data.
Owned(Rc<dyn IntoContextElement>),
Owned(Rc<dyn IntoContextElement + 'a>),
Borrowed(&'a dyn IntoContextElement),
}