anchor.diff:  -module(nif_SUITE).
   
   %%-define(line_trace,true).
  --define(CHECK(Exp,Got), check(Exp,Got,?LINE)).
  +-define(CHECK(Exp,Got), Exp = check(Exp,Got,?LINE)).
   %%-define(CHECK(Exp,Got), Exp = Got).
   
   -include_lib("common_test/include/ct.hrl").
  
positive.code:                               ]),
      ?CHECK([{upgrade,2,1,201}], nif_mod_call_history()),
      true = erlang:purge_module(nif_mod),
      ?CHECK([{unload,1,1,106}], nif_mod_call_history()),
  
      BinA2 = read_resource(0,A2),
      ok = forget_resource(A2),
  
negative.code:     ?CHECK([], nif_mod_call_history()),    % no dtor
  
      ok = forget_resource(BGX2),  % calling dtor in orphan library v1 still loaded
      ?CHECK([{{resource_dtor_B_v1,BinBGX2},1,6,106}, {unload,1,7,107}],
             nif_mod_call_history()),
  
      ok = forget_resource(NGX2),
      ?CHECK([], nif_mod_call_history()),  % no dtor
  