From 61e7ee4cc342a00c979ba0c5d67c640588407c09 Mon Sep 17 00:00:00 2001 From: "C. Guy Yarvin" Date: Thu, 21 Jul 2016 22:08:57 -0700 Subject: [PATCH] Add +-nip to ++to. --- arvo/hoon.hoon | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/arvo/hoon.hoon b/arvo/hoon.hoon index f6825eeb0e..2011094607 100644 --- a/arvo/hoon.hoon +++ b/arvo/hoon.hoon @@ -2860,12 +2860,21 @@ [n.a l.a q.b] [n.q.b [n.a l.a l.q.b] r.q.b] :: - +- nap :: removes head + +- nap :: remove head ?> ?=(^ a) ?: =(~ l.a) r.a =+ b=get(a l.a) bal(a ^+(a [p.b q.b r.a])) :: + +- nip :: remove root + |- ^+ a + ?~ a ~ + ?~ l.a r.a + ?~ r.a l.a + ?: (vor n.l.a n.r.a) + [n.l.a l.l.a $(l.a r.l.a)] + [n.r.a $(r.a l.r.a) r.r.a] + :: +- put :: insert new tail |* b/* |- ^+ a