anchor.diff:           overwritten_UUIDs/1,
            mark_pending_delete/2,
            mark_scheduled_delete/2,
  -         filter_pending_delete_uuid_manifests/1,
  -         prune/1,
  -         prune/2,
            upgrade_wrapped_manifests/1,
            upgrade_manifest/1]).
   
  
positive.code:     end,
      orddict:map(MapFun, Dict).
  
  %% @doc Return the current `pending_delete' manifests
  %% from an orddict of manifests.
  -spec filter_pending_delete_uuid_manifests(orddict:orddict()) -> [cs_uuid_and_manifest()].
  filter_pending_delete_uuid_manifests(Dict) ->
      orddict:to_list(orddict:filter(fun pending_delete_manifest/2, Dict)).
  
  %% @doc Remove all manifests that require pruning,
  %%      see needs_pruning() for definition of needing pruning.
  -spec prune(orddict:orddict()) -> orddict:orddict().
  prune(Dict) ->
      prune(Dict, erlang:now()).
  
  -spec prune(orddict:orddict(), erlang:timestamp()) -> orddict:orddict().
  prune(Dict, Time) ->
      orddict:from_list(
        [KV || {_K, V}=KV <- orddict:to_list(Dict), not (needs_pruning(V, Time))]
       ).
  
  -spec upgrade_wrapped_manifests([orddict:orddict()]) -> [orddict:orddict()].
  upgrade_wrapped_manifests(ListofOrdDicts) ->
      DictMapFun = fun (_Key, Value) -> upgrade_manifest(Value) end,
  
negative.code:     end;
  most_recent_active_manifest(Man1=?MANIFEST{state=active}, _Man2) -> Man1;
  most_recent_active_manifest(_Man1, Man2=?MANIFEST{state=active}) -> Man2.
  