indents(c): add zero_indent for #if

This commit is contained in:
Stephan Seitz 2022-01-22 18:24:38 +01:00
parent 616dc885fc
commit fd5a551d7c
7 changed files with 18 additions and 13 deletions

View file

@ -26,16 +26,20 @@
(compound_statement "}" @indent_end)
[
"else"
")"
"}"
(statement_identifier)
] @branch
[
"#define"
"#ifdef"
"#if"
"#else"
"else"
"#endif"
")"
"}"
] @branch
] @zero_indent
[
(preproc_arg)
@ -47,7 +51,7 @@
([(argument_list) (parameter_list)] @aligned_indent
(#set! "delimiter" "()"))
([ (ERROR) (comment) ] @aligned_indent
((comment) @aligned_indent
(#lua-match? @aligned_indent "^/\*"))
((comment) @ignore
(#lua-match? @ignore "^//"))