summaryrefslogtreecommitdiff
path: root/ale_linters/ocamlinterface/merlin.vim
blob: 799490f71a95db53d401b1ccb0bae06f6a60a545 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
" Author: Andrey Popp -- @andreypopp
" Description: Report errors in OCaml code with Merlin

if !exists('g:merlin')
    finish
endif

function! ale_linters#ocamlinterface#merlin#Handle(buffer, lines) abort
    return merlin#ErrorLocList()
endfunction

call ale#linter#Define('ocamlinterface', {
\   'name': 'merlin',
\   'executable': 'ocamlmerlin',
\   'command': 'true',
\   'callback': 'ale_linters#ocamlinterface#merlin#Handle',
\})