anchor.diff:                  false -> false
               end
       end;
  -
  +%%==============================================================================
  +
  +%% Other instructions are not in race with receive or after, if not caught by
  +%% the message checking part.
  +dependent({_Lid1, {   _Any, _Details1}, _Msgs1},
  +          {_Lid2, {Receive, _Details2}, _Msgs2},
  +          _CheckMsg, ?ONLY_AFTER_SWAP) when
  +      Receive =:= 'after';
  +      Receive =:= 'receive' ->
  +    false;
  +
  +%% %% Swapped version, as the message checking code can force a swap.
  +dependent({_Lid1, {Receive, _Details1}, _Msgs1},
  +          {_Lid2, {   _Any, _Details2}, _Msgs2},
  +          _CheckMsg, ?ONLY_AFTER_SWAP) when
  +      Receive =:= 'after';
  +      Receive =:= 'receive' ->
  +    false;
  +
  +%%==============================================================================
  +%% From here onwards, we have taken care of messaging races.
  +%%==============================================================================
   
   %% ETS operations live in their own small world.
   dependent({_Lid1, {ets, Op1}, _Msgs1},
  
positive.code:                 case orddict:find(Lid2, Msgs1) of
                      {ok, MsgsToLid2} ->
                          Fun =
                              case Tag of
                                  'after' -> Info;
                                  'receive' ->
                                      Target = element(3, Info),
  
negative.code:           {_Lid2, {exit, {normal, {_Tables, {ok, TName}, _Links}}}, _Msgs2},
            _CheckMsg, _AllowSwap) ->
      true;
  dependent({_Lid1, {send, _Details1}, _Msgs1},
            {_Lid2, {exit, _Details2}, _Msgs2},
            _CheckMsg, _AllowSwap) ->
      false;
  
  %%==============================================================================
  
  %% Register and unregister have the same dependencies.
  %% Use a unique value for the Pid to avoid checks there.
  dependent({Lid, {unregister, RegName}, Msgs}, B, CheckMsg, AllowSwap) ->
      dependent({Lid, {register, {RegName, make_ref()}}, Msgs}, B,
                CheckMsg, AllowSwap);
  dependent(A, {Lid, {unregister, RegName}, Msgs}, CheckMsg, AllowSwap) ->
      dependent(A, {Lid, {register, {RegName, make_ref()}}, Msgs},
                CheckMsg, AllowSwap);
  
  %%==============================================================================
  
  %% Send using name before process has registered itself (or after ungeristering).
  dependent({_Lid1, {register,      {RegName, _TLid}}, _Msgs1},
            {_Lid2, {    send, {RegName, _Lid, _Msg}}, _Msgs2},
            _CheckMsg, _AllowSwap) ->
      true;
  
  %% No other races between register and send.
  dependent({_Lid1, {register, _Details1}, _Msgs1},
            {_Lid2, {    send, _Details2}, _Msgs2},
            _CheckMsg, _AllowSwap) ->
      false;
  
  %%==============================================================================
  
  %% Two registers using the same name or the same process.
  dependent({_Lid1, {register, {RegName1, TLid1}}, _Msgs1},
  