anchor.diff:  -define(stats_inc, ok).
   -endif.
   
  +-ifdef(STACK).
  +
  +-define(show_stack(Trace), io:format("~p\n",[get_stack(Trace)])).
  +           
  +get_stack(Trace) ->
  +  get_stack(Trace, []).
  +
  +get_stack([], Acc) -> Acc;
  +get_stack([#state{last = P}|Rest], Acc) -> get_stack(Rest, [P|Acc]).
  +
  +-else.
  +
  +-define(show_stack(_Trace), ok).
  +
  +-endif.
  +
   test(M) ->
     InitPStates = dict:store(M, new_pstate(M), dict:new()),
     ?stats_start,
  
positive.code: 
  %% -define(DEBUG, true).
  %% -define(STEPWISE, true).
  %% -define(STATS, true).
  
  -ifdef(DEBUG).
  -define(STACK, true).
  -endif.
  
  %%------------------------------------------------------------------------------
  
negative.code: p(d) ->
    [rec,
     {send, m1},
     exit];
  
  p(m2) ->
    [{spawn, x},
     {spawn, y},
     {spawn, z},
     {spawn, w},
     {send, y},
     exit];
  p(x) ->
    [rec,
     {send,y},
     exit];
  p(y) ->
    [rec,
     rec,
     exit];
  p(z) ->
    [rec,
     {send,x},
     exit];
  p(w) ->
    [{send,z},
     exit].
  
  %%------------------------------------------------------------------------------
  
  