Skip to content

Commit 7a6e384

Browse files
author
Matt Fowles
committed
cl comments
1 parent e1febc9 commit 7a6e384

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

autoload/codefmt.vim

+2-2
Original file line numberDiff line numberDiff line change
@@ -234,7 +234,7 @@ function! codefmt#GetClangFormatFormatter() abort
234234
let l:supports_cursor = s:ClangFormatHasAtLeastVersion([3, 4])
235235
if l:supports_cursor
236236
" line2byte counts bytes from 1, and col counts from 1, so -2
237-
let l:cursor_pos = line2byte(line(".")) + col(".") - 2
237+
let l:cursor_pos = line2byte(line('.')) + col('.') - 2
238238
let l:cmd += ['-cursor', string(l:cursor_pos)]
239239
endif
240240

@@ -250,7 +250,7 @@ function! codefmt#GetClangFormatFormatter() abort
250250
let l:clang_format_output_json = maktaba#json#Parse(l:formatted[0])
251251
let l:new_cursor_pos =
252252
\ maktaba#ensure#IsNumber(l:clang_format_output_json.Cursor) + 1
253-
exec "goto " . l:new_cursor_pos
253+
execute 'goto' l:new_cursor_pos
254254
catch
255255
call maktaba#error#Warn('Unable to parse clang-format cursor pos: %s',
256256
\ v:exception)

0 commit comments

Comments
 (0)