X-Git-Url: https://git.rmz.io/dotfiles.git/blobdiff_plain/aeecb4f5dde5ef4ffbcdc27940616fdd24b8d29d..6d992efe5d8e98f16dc5882907ea9d8791b33e89:/vim/ftplugin/cpp.vim diff --git a/vim/ftplugin/cpp.vim b/vim/ftplugin/cpp.vim index edc1f32..c76f79b 100644 --- a/vim/ftplugin/cpp.vim +++ b/vim/ftplugin/cpp.vim @@ -43,14 +43,21 @@ let g:switch_const_definitions = \ 'const \([[:alnum:]_:<>]\{-}\) &': '\1 ' \ } ] -nnoremap c :call switch#Switch(g:switch_const_definitions, {}) +nnoremap c :call switch#Switch({'definitions': g:switch_const_definitions}) + +" Disable ale as we use ycm +let b:ale_enabled = 0 nnoremap gd :YcmCompleter GoTo nnoremap d :vs:YcmCompleter GoTo +nnoremap gD :YcmCompleter GoToReferences + +nnoremap fi :YcmCompleter FixIt " format with = -map = (operator-clang-format) -vnoremap = :ClangFormat +call operator#user#define_ex_command('ycmcompleter-format', 'YcmCompleter Format') +map = (operator-ycmcompleter-format) +vnoremap = :YcmCompleter Format " restore = mapping to g= nnoremap g= = vnoremap g= =