shrub/j/6/bull.c

35 lines
607 B
C
Raw Normal View History

2013-12-26 21:12:07 +04:00
/* j/6/bull.c
**
** This file is in the public domain.
*/
#include "all.h"
2014-09-04 07:10:43 +04:00
2013-12-26 21:12:07 +04:00
/* functions
*/
2014-09-06 00:13:24 +04:00
u3_noun
u3_cqf_bull(
u3_noun bid,
u3_noun der)
2013-12-26 21:12:07 +04:00
{
2014-01-02 00:47:18 +04:00
if ( (c3__void == der) ||
2014-09-06 00:13:24 +04:00
(c3__void == u3t(u3t(u3t(bid)))) )
2014-01-02 00:47:18 +04:00
{
2013-12-26 21:12:07 +04:00
return c3__void;
}
2014-09-06 00:13:24 +04:00
else return u3nt
(c3__bull, u3k(bid), u3k(der));
2013-12-26 21:12:07 +04:00
}
2014-09-06 00:13:24 +04:00
u3_noun
u3_cwf_bull(
u3_noun cor)
2013-12-26 21:12:07 +04:00
{
2014-09-06 00:13:24 +04:00
u3_noun bid, der;
2013-12-26 21:12:07 +04:00
2014-11-06 03:20:01 +03:00
if ( c3n == u3r_mean(cor, u3v_sam_2, &bid, u3v_sam_3, &der, 0) ) {
return u3m_bail(c3__fail);
2013-12-26 21:12:07 +04:00
} else {
2014-09-06 00:13:24 +04:00
return u3_cqf_bull(bid, der);
2013-12-26 21:12:07 +04:00
}
}