Why emacs Tuareg mode shows different color for functions in Ocaml?

428 Views Asked by At

Just want to know why Tuareg mode shows different colour for functions?

for example, as shown below, function create_percolation and index_of show blue color and is_open is in brown color.

Why??

enter image description here

1

There are 1 best solutions below

0
On BEST ANSWER

It is simply a bug of Tuareg. If the first arg of function is a record, Tuareg fails to recognize it as a function definition. Tuareg is written in emacs lisp and itself knows nothing about OCaml syntax tree like OCaml compiler does. So you should not expect something perfect from it. If you do not like it, how about submit a bug report to tuareg mode development website?