/* return the number of words or sub-expressions in the expression */ int expr_len(Expr *expr) { if (expr == NULL) return -1; if (expr_is_word(expr)) return -1; return tree_count_children(expr); }
/* * Return the number of children a binary tree has. */ int pdb_count_children_tree_cb(struct pdb_node_t* nptr) { return tree_count_children(nptr->data); }