From: Christian Brabandt Date: Thu, 2 Apr 2026 17:52:49 +0000 (+0000) Subject: runtime(preproc_indent): Ignore Swapfiles when loading buffers X-Git-Tag: v9.2.0285~2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=9d83ca5ca2796680ac90df6332afad2599183b88;p=thirdparty%2Fvim.git runtime(preproc_indent): Ignore Swapfiles when loading buffers Signed-off-by: Christian Brabandt --- diff --git a/runtime/tools/preproc_indent.vim b/runtime/tools/preproc_indent.vim index 035ca0e247..b6d296a61e 100644 --- a/runtime/tools/preproc_indent.vim +++ b/runtime/tools/preproc_indent.vim @@ -16,7 +16,7 @@ vim9script # deleted. # # Author: Hirohito Higashi (@h-east) -# Last Update: 2026 Jan 12 +# Last Update: 2026 Apr 02 def Get_C_source_files(): list var list_of_c_files: list = [] @@ -30,7 +30,7 @@ def Get_C_source_files(): list enddef def FixPreprocessorIndent(fname: string) - execute 'edit! ' .. fname + execute 'noswapfile edit! ' .. fname var nest: number = 0 var indent_offset: number = 0 # -1 if whole-file guard detected