From 7a523dde57cc4364ec314b34c3b429a99935b275 Mon Sep 17 00:00:00 2001 From: Dan Gohman Date: Sat, 9 Jan 2010 17:22:48 +0000 Subject: Tighten up the vim LLVM IR syntax highlighting regex for labels, and add a highlighting rule for identifiers. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@93056 91177308-0d34-0410-b5e6-96231b3b80d8 --- utils/vim/llvm.vim | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'utils') diff --git a/utils/vim/llvm.vim b/utils/vim/llvm.vim index 451013e..6e4a207 100644 --- a/utils/vim/llvm.vim +++ b/utils/vim/llvm.vim @@ -71,7 +71,8 @@ syn keyword llvmBoolean true false syn keyword llvmConstant zeroinitializer undef null syn match llvmComment /;.*$/ syn region llvmString start=/"/ skip=/\\"/ end=/"/ -syn match llvmLabel /[\-a-zA-Z\$._0-9]*:/ +syn match llvmLabel /[-a-zA-Z$._][-a-zA-Z$._0-9]*:/ +syn match llvmIdentifier /[%@][-a-zA-Z$._][-a-zA-Z$._0-9]*/ " Syntax-highlight dejagnu test commands. syn match llvmSpecialComment /;\s*RUN:.*$/ @@ -101,6 +102,7 @@ if version >= 508 || !exists("did_c_syn_inits") HiLink llvmConstant Constant HiLink llvmSpecialComment SpecialComment HiLink llvmError Error + HiLink llvmIdentifier Identifier delcommand HiLink endif -- cgit v1.1