vim-lambdify
vim-lambdify copied to clipboard
Support Purescript
Ended up here from https://github.com/purescript/purescript/issues/2289. Your plugin seems like a nice idea for me :-) So I'm opening this feature request.
I've tried to add support locally since it should have been a trivial copy of the Haskell/Elm implementation but it seems to enter in conflict with the well known https://github.com/raichoo/purescript-vim and there's no lambdification.
I've discovered there's a new fix for such cases of wishing to apply conceal over syntax groups through :call matchadd('Conceal', '\\', 10, 99, {'conceal': 'λ'})
, for example, Maybe it should be adopted in the implementation of the functionality of this plugin.
FYI, this is how I'm applying the lambda conceal on my .vimrc
now:
set conceallevel=2
au FileType purescript set concealcursor=vin
au WinEnter,BufEnter,BufRead,FileType,Colorscheme *
\ if exists('w:lambda_conceal') |
\ call matchdelete(w:lambda_conceal) |
\ unlet w:lambda_conceal |
\ endif |
\ if &ft == 'purescript' |
\ let w:lambda_conceal = matchadd('Conceal', '\\\%([^\\]\+→\)\@=', 10, -1, {'conceal': 'λ'}) |
\ hi! link Conceal Operator |
\ endif