;; haskell mode
(add-hook 'haskell-mode-hook 'turn-on-haskell-indentation)
+
+;; ocaml
+(add-hook 'tuareg-mode-hook 'tuareg-imenu-set-imenu)
+(setq auto-mode-alist
+ (append '(("\\.ml[ily]?$" . tuareg-mode)
+ ("\\.topml$" . tuareg-mode))
+ auto-mode-alist))
+(autoload 'utop-setup-ocaml-buffer "utop" "Toplevel for OCaml" t)
+(add-hook 'tuareg-mode-hook 'utop-setup-ocaml-buffer)
+(add-hook 'tuareg-mode-hook 'merlin-mode)
+(setq merlin-use-auto-complete-mode t)
+(setq merlin-error-after-save nil)