anchor.diff:  		Results ->
   		    output_atom_warning_msg(Pid, not_renamed_warn_msg(Fun), renamed_warn_msg(Fun)),
   		    stop_atom_process(Pid),
  -		    write_files(Editor, [{{FileName, FileName}, AnnAST1}| Results])
  +		    write_files(Editor, [{{FileName, FileName}, AnnAST1}| Results], Cmd)
   	    catch
   		throw:Err ->
   		    stop_atom_process(Pid),
  
positive.code: 		Results ->
  		    output_atom_warning_msg(Pid, not_renamed_warn_msg(Fun), renamed_warn_msg(Fun)),
  		    stop_atom_process(Pid),
  		    write_files(emacs, [{{FileName, FileName}, AnnAST1}| Results])
  	    catch
  		throw:Err -> Err
  	    end;
  	false ->
  	    output_atom_warning_msg(Pid, not_renamed_warn_msg(Fun), renamed_warn_msg(Fun)),
  	    stop_atom_process(Pid),
  	    write_files(emacs, [{{FileName, FileName}, AnnAST1}])
      end.
  
  %%-spec(write_files/2::(Editor::atom(), Results::[{{filename(), filename()}, syntaxTree()}]) ->
  %%	     {ok, [filename()]} | {ok, [{filename(), filename(), string()}]}).
  write_files(Editor, Results) ->    
      case Editor of 
  	emacs ->
  	    refac_util:write_refactored_files_for_preview(Results),
  	    ChangedFiles = [F ||{{F, _F}, _AST}<-Results],
  	    ?wrangler_io("The following files are to be changed by this refactoring:\n~p\n",
  			 [ChangedFiles]),
  
negative.code: 	false ->
  	    output_atom_warning_msg(Pid, not_renamed_warn_msg(Fun), renamed_warn_msg(Fun)),
  	    stop_atom_process(Pid),
  	    write_files(Editor, [{{FileName, FileName}, AnnAST1}], Cmd)
      end.
  
  -spec(rename_fun_1/6::(string(), integer(), integer(), string(), [dir()], integer()) ->
  	     {error, string()} | {ok, [filename()]}).
  rename_fun_1(FileName, Line, Col, NewName, SearchPaths, TabWidth) ->
      Cmd = "CMD: " ++ atom_to_list(?MODULE) ++ ":rename_fun(" ++ "\"" ++
  	FileName ++ "\", " ++ integer_to_list(Line) ++
  	", " ++ integer_to_list(Col) ++ ", " ++ "\"" ++ NewName ++ "\","
  	++ "[" ++ refac_util:format_search_paths(SearchPaths) ++ "]," ++ integer_to_list(TabWidth) ++ ").",    
      {ok, {AnnAST, Info}} = refac_util:parse_annotate_file(FileName, true, SearchPaths, TabWidth),
      NewName1 = list_to_atom(NewName),
      {ok, {Mod, Fun, Arity, _, DefinePos}} = refac_util:pos_to_fun_name(AnnAST, {Line, Col}),
  