Skip to content

Commit 43d98fe

Browse files
committed
vim: improve attribute handling
The attribute can be applied to a typename or a type declaration. Correct the handling for the second case.
1 parent e0b220c commit 43d98fe

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

utils/vim/syntax/swift.vim

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -180,7 +180,7 @@ syn match swiftPreproc /#\(\<file\>\|\<line\>\|\<function\>\)/
180180
syn match swiftPreproc /^\s*#\(\<if\>\|\<else\>\|\<elseif\>\|\<endif\>\|\<error\>\|\<warning\>\)/
181181
syn region swiftPreprocFalse start="^\s*#\<if\>\s\+\<false\>" end="^\s*#\(\<else\>\|\<elseif\>\|\<endif\>\)"
182182

183-
syn match swiftAttribute /@\<\w\+\>/ skipwhite skipempty nextgroup=swiftType
183+
syn match swiftAttribute /@\<\w\+\>/ skipwhite skipempty nextgroup=swiftType,swiftTypeDefinition
184184

185185
syn keyword swiftTodo MARK TODO FIXME contained
186186

0 commit comments

Comments
 (0)