-static inline int fast_find_open(bp *b,int s)
-{
- int r;
- r = bwd_excess(b,s,0);
- if (r >= -1) return r+1;
- return -1;
-}
-
-static inline int fast_find_close(bp *b,int s)
-{
- return fwd_excess(b,s,-1);
-}
-
-static inline int fast_find_parent_close(bp *b,int s)
-{
- return fwd_excess(b,s,-2);
-}
-
-
-static inline int fast_inspect(bp* Par,treeNode i)
-{
- int j,l;
- j = i >> logD;
- l = i & (D-1);
- return (Par->B[j] >> (D-1-l)) & 1;
-}
-
-static bool fast_isleaf(bp* Par,treeNode x){
- return (fast_inspect(Par, x+1) == CP);
-}
-
-static treeNode fast_first_child(bp *Par, treeNode x)
-{
- x = x+1;
- return (fast_inspect(Par,x) == OP) ? x : NULLT;
-}
-
-inline static treeNode fast_next_sibling(bp* Par,treeNode x)
-{
- treeNode y = fast_find_close(Par,x)+1;
- return (fast_inspect(Par, y) == OP) ? y : NULLT;
-}
-
-inline static bool fast_is_ancestor(bp * Par,treeNode x,treeNode y){
- return (x <= y) && ((x==0) || (y <= fast_find_close(Par,x)));
-}