anchor.diff:  	true ->
   	    case lists:member({NewFunName, Arity}, refac_rename_fun:testserver_callback_funs()) of 
   		true ->
  -		    throw({warning, "The new function name means that"
  +		    throw({warning, "The new function name means that "
   			   "the new function is a Test Server callback function, continue?"});
   		false -> ok
   	    end;
  
positive.code:     check_unsafe_vars(ExpList),
      funcall_replaceable(Fun, ExpList),
      TestFrameWorkUsed = refac_util:test_framework_used(FileName),
      catch test_framework_aware_name_checking(TestFrameWorkUsed, NewFunName, length(FrVars)).
  
  
  check_unsafe_vars(ExpList) ->
  
negative.code: %% =============================================================================================
  -module(refac_new_fun).
  
  -export([fun_extraction/5, fun_extraction_1/5, fun_extraction_eclipse/5, fun_extraction_1_eclipse/5]).
  
  
  -include("../include/wrangler.hrl").
  
  %% =============================================================================================
  -spec(fun_extraction/5::(filename(), pos(), pos(), string(), integer()) ->
  	     {'ok', [string()]}).
  fun_extraction(FileName, Start, End, NewFunName, TabWidth) ->
      fun_extraction(FileName, Start, End, NewFunName, TabWidth, emacs).
  
  fun_extraction_1(FileName, Start, End, NewFunName, TabWidth) ->
      fun_extraction_1(FileName, Start, End, NewFunName, TabWidth, emacs).
  
  -spec(fun_extraction_eclipse/5::(filename(), pos(), pos(), string(),integer()) ->
  	      {ok, [{filename(), filename(), string()}]}).
  fun_extraction_eclipse(FileName, Start, End, NewFunName, TabWidth) ->
      fun_extraction(FileName, Start, End, NewFunName, TabWidth, eclipse).
  
  fun_extraction_1_eclipse(FileName, Start, End, NewFunName, TabWidth) ->
      fun_extraction_1(FileName, Start, End, NewFunName, TabWidth, eclipse).
  
  
  fun_extraction_1(FileName, Start={Line, Col}, End={Line1, Col1}, NewFunName, TabWidth, Editor) ->
      Cmd = "CMD: " ++ atom_to_list(?MODULE) ++ ":fun_extraction(" ++ "\"" ++
  	FileName ++ "\", {" ++ integer_to_list(Line) ++	", " ++ integer_to_list(Col) ++ "},"++
  	"{" ++ integer_to_list(Line1) ++ ", " ++ integer_to_list(Col1) ++ "},"  ++ "\"" ++ NewFunName ++ "\","
  	++ integer_to_list(TabWidth) ++ ").",
      {ok, {AnnAST, _Info}} = refac_util:parse_annotate_file(FileName, true, [], TabWidth),
      ExpList = refac_util:pos_to_expr_list(AnnAST, Start, End),
      {ok, Fun} = refac_util:expr_to_fun(AnnAST, hd(ExpList)),
      fun_extraction_1(FileName, AnnAST, End, Fun, ExpList, NewFunName, Editor, Cmd).
  
  
  fun_extraction(FileName, Start = {Line, Col}, End = {Line1, Col1},NewFunName, TabWidth, Editor) ->
      ?wrangler_io("\nCMD: ~p:fun_extraction(~p, {~p,~p}, {~p,~p}, ~p, ~p).\n",
  		 [?MODULE, FileName, Line, Col, Line1, Col1, NewFunName, TabWidth]),
      Cmd = "CMD: " ++ atom_to_list(?MODULE) ++ ":fun_extraction(" ++ "\"" ++
  	FileName ++ "\", {" ++ integer_to_list(Line) ++	", " ++ integer_to_list(Col) ++ "},"++
  	"{" ++ integer_to_list(Line1) ++ ", " ++ integer_to_list(Col1) ++ "},"  ++ "\"" ++ NewFunName ++ "\","
  	++ integer_to_list(TabWidth) ++ ").",    
      case refac_util:is_fun_name(NewFunName) of
        true -> ok;
        false -> throw({error, "Invalid function name!"})
      end,
      {ok, {AnnAST, Info}} = refac_util:parse_annotate_file(FileName, true, [], TabWidth),
      case refac_util:pos_to_expr_list(AnnAST, Start, End) of
  	[] -> ExpList = [],
  	      throw({error, "You have not selected an expression or a sequence of expressions, "
  		     "or the function containing the expression(s) selected is malformed."});
  	ExpList -> ExpList
      end,
      {ok, Fun} = refac_util:expr_to_fun(AnnAST, hd(ExpList)),
      ok=side_cond_analysis(FileName, Info, Fun, ExpList, list_to_atom(NewFunName)),
      fun_extraction_1(FileName, AnnAST, End, Fun, ExpList, NewFunName, Editor, Cmd).
  
  
  
  fun_extraction_1(FileName, AnnAST, End, Fun, ExpList, NewFunName, Editor,Cmd) ->
      FunName = refac_syntax:atom_value(refac_syntax:function_name(Fun)),
      FunArity = refac_syntax:function_arity(Fun),
      {FrVars, BdVars} = get_free_bd_vars(ExpList),
      VarsToExport = vars_to_export(Fun, End, BdVars),
      AnnAST1 = do_fun_extraction(AnnAST, ExpList, NewFunName,FrVars, VarsToExport, FunName, FunArity),
      case Editor of
        emacs ->
  	  Res = [{{FileName, FileName}, AnnAST1}],
  	  refac_util:write_refactored_files_for_preview(Res, Cmd),
  	  {ok, [FileName]};
        eclipse ->
  	  FileContent = refac_prettypr:print_ast(refac_util:file_format(FileName), AnnAST1),
  	  {ok, [{FileName, FileName, FileContent}]}
      end.
  
  