blob: b2b3aa0fcdd7b42a37227d879e9b9d7f83809d7c [file] [log] [blame]
Benno Schulenbergc4b344f2014-02-23 16:07:44 +00001## Syntax highlighting for OCaml.
2
Chris Allegretta215eb362008-10-01 00:49:19 +00003syntax "ocaml" "\.mli?$"
Mike Scalora6a2032f2016-05-25 22:13:50 +02004comment "(*|*)"
Benno Schulenbergfe9da942014-05-16 20:21:34 +00005
Benno Schulenberg26bc0372015-12-30 20:57:31 +00006# Uid:
Chris Allegretta215eb362008-10-01 00:49:19 +00007color red "\<[A-Z][0-9a-z_]{2,}\>"
Benno Schulenberg26bc0372015-12-30 20:57:31 +00008# Declarations:
Chris Allegretta215eb362008-10-01 00:49:19 +00009color green "\<(let|val|method|in|and|rec|private|virtual|constraint)\>"
Benno Schulenberg26bc0372015-12-30 20:57:31 +000010# Structure items:
Chris Allegretta215eb362008-10-01 00:49:19 +000011color red "\<(type|open|class|module|exception|external)\>"
Benno Schulenberg26bc0372015-12-30 20:57:31 +000012# Patterns:
Chris Allegretta215eb362008-10-01 00:49:19 +000013color blue "\<(fun|function|functor|match|try|with)\>"
Benno Schulenberg26bc0372015-12-30 20:57:31 +000014# Pattern modifiers:
Benno Schulenbergfe9da942014-05-16 20:21:34 +000015color yellow "\<(as|when|of)\>"
Benno Schulenberg26bc0372015-12-30 20:57:31 +000016# Conditions:
Chris Allegretta215eb362008-10-01 00:49:19 +000017color cyan "\<(if|then|else)\>"
Benno Schulenberg26bc0372015-12-30 20:57:31 +000018# Blocks:
Chris Allegretta215eb362008-10-01 00:49:19 +000019color magenta "\<(begin|end|object|struct|sig|for|while|do|done|to|downto)\>"
Benno Schulenberg26bc0372015-12-30 20:57:31 +000020# Constants:
Chris Allegretta215eb362008-10-01 00:49:19 +000021color green "\<(true|false)\>"
Benno Schulenberg26bc0372015-12-30 20:57:31 +000022# Modules/classes:
Chris Allegretta215eb362008-10-01 00:49:19 +000023color green "\<(include|inherit|initializer)\>"
Benno Schulenberg26bc0372015-12-30 20:57:31 +000024# Expression modifiers:
Chris Allegretta215eb362008-10-01 00:49:19 +000025color yellow "\<(new|ref|mutable|lazy|assert|raise)\>"
Benno Schulenberg26bc0372015-12-30 20:57:31 +000026# Comments:
Chris Allegretta215eb362008-10-01 00:49:19 +000027color white start="\(\*" end="\*\)"
Benno Schulenberg26bc0372015-12-30 20:57:31 +000028# Strings: (no multiline handling yet)
Chris Allegretta215eb362008-10-01 00:49:19 +000029color brightblack ""[^\"]*""