Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
int
Rust
提交
9cc39a05
R
Rust
项目概览
int
/
Rust
大约 1 年 前同步成功
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
R
Rust
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
9cc39a05
编写于
7月 21, 2014
作者:
B
bors
浏览文件
操作
浏览文件
下载
差异文件
auto merge of #15450 : chris-morgan/rust/vim-misc-2014-07-04, r=kballard
上级
f15d6d28
0a0c6da5
变更
1
隐藏空白更改
内联
并排
Showing
1 changed file
with
12 addition
and
3 deletion
+12
-3
src/etc/vim/syntax/rust.vim
src/etc/vim/syntax/rust.vim
+12
-3
未找到文件。
src/etc/vim/syntax/rust.vim
浏览文件 @
9cc39a05
...
...
@@ -3,7 +3,7 @@
" Maintainer: Patrick Walton <pcwalton@mozilla.com>
" Maintainer: Ben Blum <bblum@cs.cmu.edu>
" Maintainer: Chris Morgan <me@chrismorgan.info>
" Last Change: July
06
, 2014
" Last Change: July
18
, 2014
if
version
<
600
syntax
clear
...
...
@@ -38,7 +38,7 @@ syn keyword rustKeyword for in if impl let
syn
keyword rustKeyword loop once proc pub
syn
keyword rustKeyword
return
super
syn
keyword rustKeyword unsafe virtual
while
syn
keyword rustKeyword use nextgroup
=
rustModPath skipwhite skipempty
syn
keyword rustKeyword use nextgroup
=
rustModPath
,
rustModPathInUse
skipwhite skipempty
" FIXME: Scoped impl's name is also fallen in this category
syn
keyword rustKeyword
mod
trait struct enum
type
nextgroup
=
rustIdentifier skipwhite skipempty
syn
keyword rustStorage mut ref static
const
...
...
@@ -60,6 +60,10 @@ syn region rustBoxPlacementBalance start="(" end=")" containedin=rustBoxPlace
syn
region rustBoxPlacementBalance start
=
"\["
end
=
"\]"
containedin
=
rustBoxPlacement transparent
" {} are handled by rustFoldBraces
syn
region rustMacroRepeat matchgroup
=
rustMacroRepeatDelimiters start
=
"$("
end
=
")"
contains
=
TOP nextgroup
=
rustMacroRepeatCount
syn
match
rustMacroRepeatCount
".\?[*+]"
contained
syn
match
rustMacroVariable
"$\w\+"
" Reserved (but not yet used) keywords {{{2
syn
keyword rustReservedKeyword alignof be
do
offsetof priv pure sizeof typeof unsized yield
...
...
@@ -138,8 +142,9 @@ syn keyword rustBoolean true false
" If foo::bar changes to foo.bar, change this ("::" to "\.").
" If foo::bar changes to Foo::bar, change this (first "\w" to "\u").
syn
match
rustModPath
"\w\(\w\)*::[^<]"
he
=
e
-3
,
me
=
e
-3
syn
match
rustModPath
"\w\(\w\)*"
contained "
only
for
'use path;'
syn
match
rustModPath
InUse
"\w\(\w\)*"
contained "
only
for
'use path;'
syn
match
rustModPathSep
"::"
" rustModPathInUse is split out from rustModPath so that :syn-include can get the group list right.
syn
match
rustFuncCall
"\w\(\w\)*("
he
=
e
-1
,
me
=
e
-1
syn
match
rustFuncCall
"\w\(\w\)*::<"
he
=
e
-3
,
me
=
e
-3
" foo
::<
T
>()
;
...
...
@@ -233,6 +238,9 @@ hi def link rustBinNumber rustNumber
hi
def
link rustIdentifierPrime rustIdentifier
hi
def
link rustTrait rustType
hi
def
link rustMacroRepeatCount rustMacroRepeatDelimiters
hi
def
link rustMacroRepeatDelimiters Macro
hi
def
link rustMacroVariable Define
hi
def
link rustSigil StorageClass
hi
def
link rustEscape Special
hi
def
link rustEscapeUnicode rustEscape
...
...
@@ -255,6 +263,7 @@ hi def link rustReservedKeyword Error
hi
def
link rustConditional Conditional
hi
def
link rustIdentifier Identifier
hi
def
link rustCapsIdent rustIdentifier
hi
def
link rustModPathInUse rustModPath
hi
def
link rustModPath Include
hi
def
link rustModPathSep Delimiter
hi
def
link rustFunction Function
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录