Skip to content

Commit 84872a3

Browse files
committed
---
yaml --- r: 21329 b: refs/heads/snap-stage3 c: f7f909a h: refs/heads/master i: 21327: d4826b3 v: v3
1 parent f8eb960 commit 84872a3

File tree

3 files changed

+11
-11
lines changed

3 files changed

+11
-11
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
refs/heads/master: e430a699f2c60890d9b86069fd0c68a70ece7120
33
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
4-
refs/heads/snap-stage3: 5ccf8175a8ae5f6aaff30bb2330a5f05ec89028d
4+
refs/heads/snap-stage3: f7f909a8cffad997b96debbcf4fea47cec64ba19
55
refs/heads/try: ffbe0e0e00374358b789b0037bcb3a577cd218be
66
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
77
refs/heads/ndm: f3868061cd7988080c30d6d5bf352a5a5fe2460b

branches/snap-stage3/src/etc/vim/indent/rust.vim

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,4 @@ if exists("b:did_indent")
55
endif
66

77
let b:did_indent = 1
8-
setlocal cindent
9-
setlocal cinkeys-=0#
10-
setlocal cino=j1,J1
8+
setlocal smartindent

branches/snap-stage3/src/etc/vim/syntax/rust.vim

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -10,14 +10,13 @@ elseif exists("b:current_syntax")
1010
finish
1111
endif
1212

13-
syn keyword rustAssert assert
14-
syn match rustAssert "assert\(\w\)*"
15-
syn keyword rustKeyword alt again as break
16-
syn keyword rustKeyword check claim const copy do drop else export extern fail
13+
syn match rustAssert "\<assert\(\w\)*"
14+
syn keyword rustKeyword again as break
15+
syn keyword rustKeyword const copy do drop else export extern fail
1716
syn keyword rustKeyword for if impl import in let log
1817
syn keyword rustKeyword loop match mod module move mut new of owned priv pub pure
19-
syn keyword rustKeyword ref ret return static to unchecked
20-
syn match rustKeyword "unsafe" " Allows also matching unsafe::foo()
18+
syn keyword rustKeyword ref return static to unchecked
19+
syn match rustKeyword "\<unsafe\>" " Allows also matching unsafe::foo()
2120
syn keyword rustKeyword use while with
2221
" FIXME: Scoped impl's name is also fallen in this category
2322
syn keyword rustKeyword mod trait class struct enum type nextgroup=rustIdentifier skipwhite
@@ -73,7 +72,9 @@ syn match rustFuncCall "\w\(\w\)*::<"he=e-3,me=e-3 contains=rustAssert "
7372
syn match rustMacro '\w\(\w\)*!'
7473
syn match rustMacro '#\w\(\w\)*'
7574

76-
syn region rustString start=+L\="+ skip=+\\\\\|\\"+ end=+"+ contains=rustTodo
75+
syn match rustFormat display "%\(\d\+\$\)\=[-+' #0*]*\(\d*\|\*\|\*\d\+\$\)\(\.\(\d*\|\*\|\*\d\+\$\)\)\=\([hlLjzt]\|ll\|hh\)\=\([aAbdiuoxXDOUfFeEgGcCsSpn?]\|\[\^\=.[^]]*\]\)" contained
76+
syn match rustFormat display "%%" contained
77+
syn region rustString start=+L\="+ skip=+\\\\\|\\"+ end=+"+ contains=rustTodo,rustFormat
7778

7879
syn region rustAttribute start="#\[" end="\]" contains=rustString
7980

@@ -108,6 +109,7 @@ hi def link rustHexNumber rustNumber
108109
hi def link rustBinNumber rustNumber
109110
hi def link rustIdentifierPrime rustIdentifier
110111

112+
hi def link rustFormat Special
111113
hi def link rustString String
112114
hi def link rustCharacter Character
113115
hi def link rustNumber Number

0 commit comments

Comments
 (0)