summaryrefslogtreecommitdiff
path: root/ale_linters/reason/merlin.vim
blob: 7bef7df820979f31c26d43e599a81592453dc05d (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 ReasonML code with Merlin

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

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

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