wip: make EdnItem work on Arc<str>

This commit is contained in:
🪞👃🪞 2025-01-17 18:49:04 +01:00
parent d4f962fbfa
commit 1b9da07280
17 changed files with 152 additions and 260 deletions

View file

@ -46,7 +46,7 @@ impl<E: Output, A: Content<E>> Content<E> for Align<E, A> {
}
}
impl<'a, E: Output + 'a, T: EdnViewData<'a, E>> TryFromEdn<'a, T> for Align<E, RenderBox<'a, E>> {
fn try_from_edn (state: &'a T, head: &EdnItem<&str>, tail: &'a [EdnItem<&str>]) -> Option<Self> {
fn try_from_edn (state: &'a T, head: &EdnItem, tail: &'a [EdnItem]) -> Option<Self> {
use EdnItem::*;
Some(match (head, tail) {
(Key("align/c"), [a]) => Self::c(state.get_content(a).expect("no content")),