2.3. F# without Visual Studio

You have to add some directories to PATH environment variable for the following commands:

2.3.1. F# with Vim

You have to set utf-8 mode and optionlally set guifont if you are an CJK user. For example, my _gvimrc file for gvim 6.3 is like:


	set guifont=ü:h12:cHANGEUL
	set fileencoding=utf-8
	set fileencodings=utf-8

2.3.2. F# with Emacs

The GNU Emacs 21.3 does NOT fully support UTF-8 for CJK users. Please get more recent version than 21.3.3. For example you can get a precompiled package from here.

Next, put ocaml-mode files to $EMACS/site-lisp directory.

Here is my $HOME/.emacs:


	(setq auto-mode-alist
          	(cons '("\\.ml[iylp]?$" . caml-mode) auto-mode-alist))
	(autoload 'caml-mode "caml" "Major mode for editing Caml code." t)
	(autoload 'run-caml "inf-caml" "Run an inferior Caml process." t)
	(if window-system (require 'caml-font))

	(setq save-abbrevs 'silently)

2.3.3. Examples

Here are screen shots of editing and compiling .ml files using Emacs editor. Edit the above hello.console program and presss Cntl-C CntlC, then you will see (click for larger image):

If you exectue the program in console window, you can find the output is directed to the current window (click it for larger image).

With the same procedure, the above winhello program is look like (click it for larger image):

The output is same with F# for Visual Studio.