anchor.diff:      Seg = setelement(BktI, element(SegI, Segs), Bkt),
       setelement(SegI, Segs, Seg).
   
  --spec maybe_expand(set(E), 0 | 1) -> set(E).
  -maybe_expand(T0, Ic) when T0#set.size + Ic > T0#set.exp_size ->
  +-spec maybe_expand(set(E)) -> set(E).
  +maybe_expand(T0) when T0#set.size + 1 > T0#set.exp_size ->
       T = maybe_expand_segs(T0),			%Do we need more segments.
       N = T#set.n + 1,				%Next slot to expand into
       Segs0 = T#set.segs,
  
positive.code:       Set2 :: set(Element).
  del_element(E, S0) ->
      Slot = get_slot(S0, E),
      {S1,Dc} = on_bucket(fun (B0) -> del_bkt_el(E, B0) end, S0, Slot),
      maybe_contract(S1, Dc).
  
  -spec del_bkt_el(T, [T]) -> {[T], 0 | 1}.
  del_bkt_el(E, [E|Bkt]) -> {Bkt,1};
  del_bkt_el(E, [Other|Bkt0]) ->
      {Bkt1,Dc} = del_bkt_el(E, Bkt0),
      {[Other|Bkt1],Dc};
  del_bkt_el(_, []) -> {[],0}.
  
  %% union(Set1, Set2) -> Set
  %%  Return the union of Set1 and Set2.
  
negative.code:     {B1,B2} = rehash(B, Slot1, Slot2, T#set.maxn),
      Segs1 = put_bucket_s(Segs0, Slot1, B1),
      Segs2 = put_bucket_s(Segs1, Slot2, B2),
      T#set{size = T#set.size + 1,
  	  n = N,
  	  exp_size = N * ?expand_load,
  	  con_size = N * ?contract_load,
  	  segs = Segs2};
  maybe_expand(T) -> T#set{size = T#set.size + 1}.
  
  -spec maybe_expand_segs(set(E)) -> set(E).
  maybe_expand_segs(T) when T#set.n =:= T#set.maxn ->
  