refactors u3v_boot/_lite, fixes reference miscount
@@ -26,13 +26,12 @@ _cv_life(u3_noun eve)
c3_o
u3v_boot(u3_noun eve)
{
- u3_noun pro;
-
// ensure zero-initialized kernel
//
u3A->roc = 0;
- pro = u3m_soft(0, _cv_life, eve);
+ {
+ u3_noun pro = u3m_soft(0, _cv_life, eve);
if ( u3_blip != u3h(pro) ) {
u3z(pro);
@@ -40,8 +39,9 @@ u3v_boot(u3_noun eve)
}
u3A->roc = u3k(u3t(pro));
-
u3z(pro);
+ }
+
return c3y;
}
@@ -56,7 +56,7 @@ _cv_lite(u3_noun pil)
u3x_trel(arv, &eve, 0, 0);
u3l_log("lite: arvo formula %x\r\n", u3r_mug(arv));
- pro = _cv_life(eve);
+ pro = _cv_life(u3k(eve));
u3l_log("lite: core %x\r\n", u3r_mug(pro));
u3z(arv);
@@ -67,6 +67,11 @@ _cv_lite(u3_noun pil)
*/
c3_o
u3v_boot_lite(u3_atom lit)
+{
+ // ensure zero-initialized kernel
+ //
+ u3A->roc = 0;
+
{
u3_noun pro = u3m_soft(0, _cv_lite, lit);
@@ -76,9 +81,11 @@ u3v_boot_lite(u3_atom lit)
}
u3A->roc = u3k(u3t(pro));
+ u3z(pro);
+ }
+
u3l_log("lite: final state %x\r\n", u3r_mug(u3A->roc));
- u3z(pro);
return c3y;
}
