blob: da15bce8fe71611b1653e29a31ff3ad428ac154b [file] [log] [blame]
Bram Moolenaar14b69452013-06-29 23:05:20 +02001" Vim Compiler File
2" Compiler: ocaml
3" Maintainer: See ftplugin/ocaml.vim (?)
4" Last Change: June 2013 by Marc Weber
5"
6" Marc Weber's comments:
7" Setting makeprg doesn't make sense, because there is ocamlc, ocamlopt,
8" ocamake and whatnot. So which one to use?
9"
10" This error format was moved from ftplugin/ocaml.vim to this file,
11" because ftplugin is the wrong file to set an error format
12" and the error format itself is annoying because it joins many lines in this
13" error case:
14"
15" Error: The implementation foo.ml does not match the interface foo.cmi:
16" Modules do not match case.
17"
18" So having it here makes people opt-in
19
20
21if exists("current_compiler")
22 finish
23endif
24let current_compiler = "ocaml"
25
26let s:cpo_save = &cpo
27set cpo&vim
28
29CompilerSet errorformat =
30 \%EFile\ \"%f\"\\,\ line\ %l\\,\ characters\ %c-%*\\d:,
31 \%EFile\ \"%f\"\\,\ line\ %l\\,\ character\ %c:%m,
32 \%+EReference\ to\ unbound\ regexp\ name\ %m,
33 \%Eocamlyacc:\ e\ -\ line\ %l\ of\ \"%f\"\\,\ %m,
34 \%Wocamlyacc:\ w\ -\ %m,
35 \%-Zmake%.%#,
36 \%C%m,
37 \%D%*\\a[%*\\d]:\ Entering\ directory\ `%f',
38 \%X%*\\a[%*\\d]:\ Leaving\ directory\ `%f',
39 \%D%*\\a:\ Entering\ directory\ `%f',
40 \%X%*\\a:\ Leaving\ directory\ `%f',
41 \%DMaking\ %*\\a\ in\ %f
42
43let &cpo = s:cpo_save
44unlet s:cpo_save