@@ -82,7 +82,7 @@ function s:LinuxFormatting()
82
82
endfunction
83
83
84
84
function s: LinuxKeywords ()
85
- syn keyword cStatement fallthrough
85
+ syn keyword cStatement fallthrough return_ptr
86
86
syn keyword cStorageClass noinline __always_inline __must_check
87
87
syn keyword cStorageClass __pure __weak __noclone
88
88
syn keyword cStorageClass __free __cleanup
@@ -91,10 +91,12 @@ function s:LinuxKeywords()
91
91
syn keyword cType u8 u16 u32 u64 s8 s16 s32 s64
92
92
syn keyword cType __u8 __u16 __u32 __u64 __s8 __s16 __s32 __s64
93
93
syn keyword cType __le16 __le32 __le64 __be16 __be32 __be64
94
+ syn keyword LinuxGuard guard scoped_guard scoped_cond_guard
94
95
endfunction
95
96
96
97
function s: LinuxHighlighting ()
97
98
highlight default link LinuxError ErrorMsg
99
+ highlight default link LinuxGuard cConditional
98
100
99
101
syn match LinuxError / \+\z e\t / " spaces before tab
100
102
syn match LinuxError / \% >100v[^()\{\}\[\] <>]\+ / " virtual column 101 and more
@@ -103,6 +105,9 @@ function s:LinuxHighlighting()
103
105
" include/linux/compiler_attributes.h for why.
104
106
syn match LinuxError / \< __deprecated\> /
105
107
108
+ " highlight various for_each() variants
109
+ syn match cRepeat / \v ^\s *\z s((h)?list_|device_)?for_each(_\w +)?(\( )@=/
110
+
106
111
" Highlight trailing whitespace, unless we're in insert mode and the
107
112
" cursor's placed right after the whitespace. This prevents us from having
108
113
" to put up with whitespace being highlighted in the middle of typing
0 commit comments