ocaml.nanorc (849B)
1 ## Syntax highlighting for OCaml. 2 3 syntax ocaml "\.mli?$" 4 magic "OCaml" 5 comment "(*|*)" 6 7 # Uid: 8 color red "\<[[:upper:]][[:lower:][:digit:]_]{2,}\>" 9 # Declarations: 10 color green "\<(let|val|method|in|and|rec|private|virtual|constraint)\>" 11 # Structure items: 12 color red "\<(type|open|class|module|exception|external)\>" 13 # Patterns: 14 color blue "\<(fun|function|functor|match|try|with)\>" 15 # Pattern modifiers: 16 color yellow "\<(as|when|of)\>" 17 # Conditions: 18 color cyan "\<(if|then|else)\>" 19 # Blocks: 20 color magenta "\<(begin|end|object|struct|sig|for|while|do|done|to|downto)\>" 21 # Constants: 22 color green "\<(true|false)\>" 23 # Modules/classes: 24 color green "\<(include|inherit|initializer)\>" 25 # Expression modifiers: 26 color yellow "\<(new|ref|mutable|lazy|assert|raise)\>" 27 # Comments: 28 color white start="\(\*" end="\*\)" 29 # Strings: 30 color brightblack ""[^"\]*""