Radish alpha
h
Radicle Heartwood Protocol & Stack
Radicle
Git (anonymous pull)
Log in to clone via SSH
radicle-term: Optimize impl of VStack::children()
Matthias Beyer committed 8 months ago
commit f529ff326787814f09d5d4cea67b142023346c71
parent bf12f89c8d9689ccd2114c2e72f7780e4676ad18
1 file changed +3 -4
modified crates/radicle-term/src/vstack.rs
@@ -77,10 +77,9 @@ impl<'a> VStack<'a> {
        I: IntoIterator<Item = Box<dyn Element>>,
    {
        let mut vstack = self;
-

-
        for child in children.into_iter() {
-
            vstack = vstack.child(child);
-
        }
+
        vstack
+
            .rows
+
            .extend(children.into_iter().map(|e| Row::Element(Box::new(e))));
        vstack
    }