Traversable rose tree #
Traversable and LawfulTraversable instances for the n-ary RoseTree, mirroring
Mathlib.Data.Tree.Traversable for BinaryTree. The lawfulness lemmas recurse
through the child list via traverseList, so each is proved with a small
list-level helper fed the per-child induction hypothesis from RoseTree.rec'.
@[implicit_reducible]
Equations
- RoseTree.instTraversable = { map := fun {α β : Type ?u.1} => RoseTree.map, traverse := fun {m : Type ?u.1 → Type ?u.1} [Applicative m] {α β : Type ?u.1} => RoseTree.traverse }