Skip to content

Commit 17b9f82

Browse files
committed
Improve ClangFormat to support specific parameters in "g:clang_format_style".
Example style configuration: {BasedOnStyle: Google, IndentWidth: 4, TabWidth: 4, Standard: Cpp11}
1 parent 76d9e7d commit 17b9f82

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

plugin/clang.vim

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1287,7 +1287,7 @@ endf
12871287
" Call clang-format to format source code
12881288
func! s:ClangFormat()
12891289
let l:view = winsaveview()
1290-
let l:command = printf("%s -style=%s ", g:clang_format_exec, g:clang_format_style)
1290+
let l:command = printf("%s -style=\"%s\" ", g:clang_format_exec, g:clang_format_style)
12911291
silent execute '%!'. l:command
12921292
call winrestview(l:view)
12931293
endf

0 commit comments

Comments
 (0)