diff options
author | dundargoc <gocdundar@gmail.com> | 2023-11-12 15:54:54 +0100 |
---|---|---|
committer | dundargoc <33953936+dundargoc@users.noreply.github.com> | 2023-11-13 23:39:56 +0100 |
commit | 28f4f3c48498086307ed825d1761edb5789ca0e8 (patch) | |
tree | 880d2104092261fe0457b17a9ddda8a6e0f7f2ed /src/nvim/runtime.c | |
parent | 48bcc7b9710d6db619b05254ea87f4087cdd9764 (diff) | |
download | rneovim-28f4f3c48498086307ed825d1761edb5789ca0e8.tar.gz rneovim-28f4f3c48498086307ed825d1761edb5789ca0e8.tar.bz2 rneovim-28f4f3c48498086307ed825d1761edb5789ca0e8.zip |
refactor: follow style guide
- reduce variable scope
- prefer initialization over declaration and assignment
- use bool to represent boolean values
Diffstat (limited to 'src/nvim/runtime.c')
-rw-r--r-- | src/nvim/runtime.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/src/nvim/runtime.c b/src/nvim/runtime.c index 1438385e66..83c4a68af2 100644 --- a/src/nvim/runtime.c +++ b/src/nvim/runtime.c @@ -2583,10 +2583,8 @@ char *getsourceline(int c, void *cookie, int indent, bool do_concat) } if (line != NULL && sp->conv.vc_type != CONV_NONE) { - char *s; - // Convert the encoding of the script line. - s = string_convert(&sp->conv, line, NULL); + char *s = string_convert(&sp->conv, line, NULL); if (s != NULL) { xfree(line); line = s; |