anchor.diff:  failed_avp(_, [] = No, _) ->
       No;
   
  -failed_avp(Rec, Failed, Dict) ->
  -    [fa(Rec, [{'AVP', Failed}], Dict)].
  +failed_avp(Rec, Avps, Dict) ->
  +    [failed(Rec, [{'AVP', lists:reverse(Avps)}], Dict)].
   
   %% Reply as name and tuple list ...
  -fa([MsgName | Values], FailedAvp, Dict) ->
  -    R = Dict:msg2rec(MsgName),
  +failed([MsgName | Values], FailedAvp, Dict) ->
  +    RecName = Dict:msg2rec(MsgName),
       try
  -        Dict:'#info-'(R, {index, 'Failed-AVP'}),
  +        Dict:'#info-'(RecName, {index, 'Failed-AVP'}),
           {'Failed-AVP', [FailedAvp]}
       catch
           error: _ ->
  
positive.code: 
  reset(Msg, Dict, Es)
    when is_list(Es) ->
      {E3, E5, Fs} = partition(Es),
      FailedAVP = failed_avp(Msg, lists:reverse(Fs), Dict),
      reset(set(Msg, FailedAVP, Dict),
            Dict,
            choose(is_answer_message(Msg, Dict), E3, E5));
  
negative.code:     end;
  
  %% ... or record.
  failed(Rec, FailedAvp, Dict) ->
      try
          RecName = element(1, Rec),  
          Dict:'#info-'(RecName, {index, 'Failed-AVP'}),
          {'Failed-AVP', [FailedAvp]}
      catch
          error: _ ->
  