-
Notifications
You must be signed in to change notification settings - Fork 234
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
(vim) Split the ocaml filetype into several filetypes (#1340)
from undu/ocaml_interface
- Loading branch information
Showing
5 changed files
with
32 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
" Activate merlin on current buffer | ||
call merlin#Register() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
" Activate merlin on current buffer | ||
call merlin#Register() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
" Enable Syntastic support | ||
" Make sure syntax_checkers directory is on runtime path, then set | ||
" :let g:syntastic_ocamlinterface_checkers=['merlin'] | ||
|
||
function! SyntaxCheckers_ocamlinterface_merlin_IsAvailable() | ||
if !exists("*merlin#SelectBinary") | ||
return 0 | ||
endif | ||
try | ||
let l:path = merlin#SelectBinary() | ||
return executable(l:path) | ||
catch | ||
return 0 | ||
endtry | ||
endfunction | ||
|
||
function! SyntaxCheckers_ocamlinterface_merlin_GetLocList() | ||
return merlin#ErrorLocList() | ||
endfunction | ||
|
||
call g:SyntasticRegistry.CreateAndRegisterChecker({ | ||
\ 'filetype': 'ocamlinterface', | ||
\ 'name': 'merlin'}) |