anchor.diff:  stop(Module) ->
     gen_server:cast(mod_to_name(Module), stop),
     timer:sleep(10).
  +  
  +stub_function(Module, Name, Arity, Ret) when is_function(Ret) ->
  +  {_, Bin, _} = code:get_object_code(Module),
  +  {ok, {Module,[{abstract_code,{raw_abstract_v1,Forms}}]}} = beam_lib:chunks(Bin, [abstract_code]),
  +  {Prefix, Functions} = lists:splitwith(fun(Form) -> element(1, Form) =/= function end, Forms),
  +  Function = {function,1,Name,Arity,[{clause,1,generate_variables(Arity), [], generate_expression(mock, stub_proxy_call, Module, Name, Arity)}]},
  +  RegName = list_to_atom(lists:concat([Module, "_", Name, "_stub"])),
  +  Pid = spawn_link(fun() ->
  +      stub_function_loop(Ret)
  +    end),
  +  register(RegName, Pid),
  +  Forms1 = Prefix ++ replace_function(Function, Functions),
  +  code:purge(Module),
  +  code:delete(Module),
  +  case compile:forms(Forms1, [binary]) of
  +    {ok, Module, Binary} -> code:load_binary(Module, atom_to_list(Module) ++ ".erl", Binary);
  +    Other -> Other
  +  end.
  +  
   %%====================================================================
   %% gen_server callbacks
   %%====================================================================
  
positive.code:     _ -> Acc
    end.
    
  % Function -> {function, Lineno, Name, Arity, [Clauses]}
  % Clause -> {clause, Lineno, [Variables], [Guards], [Expressions]}
  % Variable -> {var, Line, Name}
  
negative.code: %% @end
  proxy_call(Module, Function, Args) ->
    gen_server:call(mod_to_name(Module), {proxy_call, Function, Args}).
    
  stub_proxy_call(Module, Function, Args) ->
    RegName = list_to_atom(lists:concat([Module, "_", Function, "_stub"])),
    Ref = make_ref(),
    RegName ! {Ref, self(), Args},
    ?debugFmt("sending {~p,~p,~p}", [Ref, self(), Args]),
    receive
      {Ref, Answer} -> Answer
    end.
    
  %% @spec expects(Module::atom(), 
  %%               Function::atom(), 
  