Ocaml Mode - Emacs tuareg

I just started using tuareg mode in emacs to program ocaml. So can someone tell me what are the main benefits of using it? Can someone suggest me some tutorial for this?

+8
emacs ocaml tuareg
source share
3 answers

Tuareg mode is good because it can analyze code and calculate padding and blocking fonts based on this information. In addition, it provides fairly good opportunities for interactive work with code.

As for the textbook - I do not think that this exists (although I planned to write it a long time ago). All information for installation is in the README file, and you can find out about the available commands by visiting the OCaml source file and pressing Ch m to get a description of the mode, or to get a description of the tuareg-mode function (if tuareg.el already loaded).

A useful addition to these descriptions is the refare of the Tuareg mode, which lists all (or almost) available commands.

+11
source share

Tuareg is really good for:

  • Code highlighting
  • Rejecting the correct code
  • Easily send pieces of code to REPL
  • Easy compilation of your code
0
source share
  • Syntax highlighting, indentation, like (almost) all language modes.
  • Compile or evaluate at the top level from a single buffer (you no longer need to open ocaml toplevel on the command line to test some crap functions)
  • Helper mode of type Caml: after successful or partial compilation, you can easily specify a variable and get the type that was compiled for it by the compiler.
0
source share

All Articles