anchor.diff:  -spec gen_hash_node(mt_node(), InnerHf::inner_hash_fun(), LeafHf::hash_fun(),
                       KeepBucket::boolean(),
                       CleanBuckets::boolean()) -> mt_node().
  -gen_hash_node({_H, Count, _LCnt, _Bkt = [], Interval, ChildList = [_|_]},
  +gen_hash_node({_H, Count, LeafCount, _Bkt = [], Interval, ChildList = [_|_]},
                 InnerHf, LeafHf, OldKeepBucket, CleanBuckets) ->
       % inner node
       NewChilds = [gen_hash_node(X, InnerHf, LeafHf, OldKeepBucket,
                                  CleanBuckets) || X <- ChildList],
  -    LeafCount = lists:foldl(fun(N, LeafCountX) ->
  -                                    LeafCountX + get_leaf_count(N)
  -                            end, 0, NewChilds),
       Hash = run_inner_hf(NewChilds, InnerHf),
       {Hash, Count, LeafCount, [], Interval, NewChilds};
   gen_hash_node({Hash, _Cnt, _LCnt = 1, _Bkt, _I, []} = N, _InnerHf,
  
positive.code:         [] -> error_logger:error_msg("InsertFailed!"), Node;
          [Dest|_] ->
              OldSize = node_size(Dest),
              NewDest = insert_to_node(Key, CheckKey, Dest, Config),
              {Hash, Count + (node_size(NewDest) - OldSize), LeafCount, [], Interval, [NewDest|Rest]}
      end.
  %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  
  
negative.code: %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  
  %% @doc Returns the number of leafs under a bucket (1 if the requested node is
  %%      a leaf node).
  -spec get_leaf_count(merkle_tree() | mt_node()) -> -1 | pos_integer().
  get_leaf_count({merkle_tree, _, Root}) -> get_leaf_count(Root);
  get_leaf_count({_H, _Cnt, LeafCount, _Bkt, _I, _CL}) -> LeafCount.
  