annotate runtime/indent.vim @ 19760:9daed26b788b v8.2.0436

patch 8.2.0436: no warnings for incorrect printf arguments Commit: https://github.com/vim/vim/commit/db99f9f29a248b84742b6779c3343123f72065e7 Author: Bram Moolenaar <Bram@vim.org> Date: Mon Mar 23 22:12:22 2020 +0100 patch 8.2.0436: no warnings for incorrect printf arguments Problem: No warnings for incorrect printf arguments. Solution: Fix attribute in declaration. Fix uncovered mistakes. (Dominique Pelle, closes #5834)
author Bram Moolenaar <Bram@vim.org>
date Mon, 23 Mar 2020 22:15:05 +0100
parents 19ef2bbf569c
children f37561549ec2
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1 " Vim support file to switch on loading indent files for file types
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
2 "
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
3 " Maintainer: Bram Moolenaar <Bram@vim.org>
1549
19ef2bbf569c updated for version 7.1-263
vimboss
parents: 233
diff changeset
4 " Last Change: 2008 Feb 22
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
5
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
6 if exists("did_indent_on")
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
7 finish
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
8 endif
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
9 let did_indent_on = 1
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
10
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
11 augroup filetypeindent
233
fca8a9b65afa updated for version 7.0065
vimboss
parents: 7
diff changeset
12 au FileType * call s:LoadIndent()
fca8a9b65afa updated for version 7.0065
vimboss
parents: 7
diff changeset
13 func! s:LoadIndent()
fca8a9b65afa updated for version 7.0065
vimboss
parents: 7
diff changeset
14 if exists("b:undo_indent")
fca8a9b65afa updated for version 7.0065
vimboss
parents: 7
diff changeset
15 exe b:undo_indent
fca8a9b65afa updated for version 7.0065
vimboss
parents: 7
diff changeset
16 unlet! b:undo_indent b:did_indent
fca8a9b65afa updated for version 7.0065
vimboss
parents: 7
diff changeset
17 endif
1549
19ef2bbf569c updated for version 7.1-263
vimboss
parents: 233
diff changeset
18 let s = expand("<amatch>")
19ef2bbf569c updated for version 7.1-263
vimboss
parents: 233
diff changeset
19 if s != ""
233
fca8a9b65afa updated for version 7.0065
vimboss
parents: 7
diff changeset
20 if exists("b:did_indent")
fca8a9b65afa updated for version 7.0065
vimboss
parents: 7
diff changeset
21 unlet b:did_indent
fca8a9b65afa updated for version 7.0065
vimboss
parents: 7
diff changeset
22 endif
1549
19ef2bbf569c updated for version 7.1-263
vimboss
parents: 233
diff changeset
23
19ef2bbf569c updated for version 7.1-263
vimboss
parents: 233
diff changeset
24 " When there is a dot it is used to separate filetype names. Thus for
19ef2bbf569c updated for version 7.1-263
vimboss
parents: 233
diff changeset
25 " "aaa.bbb" load "indent/aaa.vim" and then "indent/bbb.vim".
19ef2bbf569c updated for version 7.1-263
vimboss
parents: 233
diff changeset
26 for name in split(s, '\.')
19ef2bbf569c updated for version 7.1-263
vimboss
parents: 233
diff changeset
27 exe 'runtime! indent/' . name . '.vim'
19ef2bbf569c updated for version 7.1-263
vimboss
parents: 233
diff changeset
28 endfor
233
fca8a9b65afa updated for version 7.0065
vimboss
parents: 7
diff changeset
29 endif
fca8a9b65afa updated for version 7.0065
vimboss
parents: 7
diff changeset
30 endfunc
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
31 augroup END