anchor.diff:  %@private
   init(_Args) ->
       ets:new(?MODULE, [set, protected, named_table]),
  +    process_flag(trap_exit, true),
       State = null,
       State.
   
  
positive.code: %     nodes in one erlang vm. But for the processes forming a scalaris
  %     node being able to talk to each other, they have to now their
  %     names (cs_node, config, etc.). This module allows the processes
  %     to keep their names. 
  %
  %     When a new process group is created, a unique "instance_id" is
  %     created, which has to be shared by all nodes in this
  %     group. 
  %     
  %     {@link register_process/3} registers the name of a process in
  %     his group and stores the instance_id in the calling processes'
  %     environment using {@link erlang:put/2}.
  
negative.code: 
  %@private
  
  -spec(on/2 :: (any(), null) -> null).
  on({register_process, InstanceId, Name, Pid}, State) ->
      case ets:insert_new(?MODULE, {{InstanceId, Name}, Pid}) of
          true ->
              link(Pid);
          false ->
              OldPid = ets:lookup_element(?MODULE, {InstanceId, Name}, 2),
              unlink(OldPid),
              link(Pid),
              ets:insert_new(?MODULE, {{InstanceId, Name}, Pid})
      end,
      cs_send:send_local(Pid , {ok}),
      State;
  on({drop_state}, State) ->
      % only for unit tests
      Links = ets:match(?MODULE, {'_', '$1'}),
      [unlink(Pid) || [Pid] <- Links],
      ets:delete_all_objects(?MODULE),
      State;
  on({'EXIT', FromPid, _Reason}, State) ->
      Processes = ets:match(?MODULE, {'$1', FromPid}),
      [ets:delete(?MODULE, {InstanceId, Name}) || [{InstanceId, Name}] <- Processes],
      State;
  on(_, _State) ->
      unknown_event.
  
  