Skip to content

Commit

Permalink
Add new keywords (particularly where & virtual) to editor modes.
Browse files Browse the repository at this point in the history
  • Loading branch information
huonw committed Aug 17, 2014
1 parent 85fd37f commit d1c5db3
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 3 deletions.
5 changes: 3 additions & 2 deletions src/etc/emacs/rust-mode.el
Expand Up @@ -170,7 +170,7 @@
(defconst rust-mode-keywords
'("as"
"box" "break"
"continue" "crate"
"const" "continue" "crate"
"do"
"else" "enum" "extern"
"false" "fn" "for"
Expand All @@ -182,7 +182,8 @@
"self" "static" "struct" "super"
"true" "trait" "type"
"unsafe" "use"
"while"))
"virtual"
"where" "while"))

(defconst rust-special-types
'("u8" "i8"
Expand Down
Expand Up @@ -71,6 +71,8 @@
<keyword>trait</keyword>
<keyword>unsafe</keyword>
<keyword>use</keyword>
<keyword>virtual</keyword>
<keyword>where</keyword>
<keyword>while</keyword>
</context>

Expand Down
3 changes: 3 additions & 0 deletions src/etc/kate/rust.xml
Expand Up @@ -19,6 +19,7 @@
<item> as </item>
<item> break </item>
<item> box </item>
<item> const </item>
<item> continue </item>
<item> crate </item>
<item> do </item>
Expand All @@ -44,6 +45,8 @@
<item> trait </item>
<item> unsafe </item>
<item> use </item>
<item> virtual </item>
<item> where </item>
<item> while </item>
</list>
<list name="traits">
Expand Down
2 changes: 1 addition & 1 deletion src/etc/vim/syntax/rust.vim
Expand Up @@ -26,7 +26,7 @@ syn keyword rustKeyword fn nextgroup=rustFuncName skipwhite skipempty
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 unsafe virtual where while
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
Expand Down

5 comments on commit d1c5db3

@bors
Copy link
Contributor

@bors bors commented on d1c5db3 Aug 17, 2014

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

saw approval from pcwalton
at huonw@d1c5db3

@bors
Copy link
Contributor

@bors bors commented on d1c5db3 Aug 17, 2014

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

merging huonw/rust/new-kw = d1c5db3 into auto

@bors
Copy link
Contributor

@bors bors commented on d1c5db3 Aug 17, 2014

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

huonw/rust/new-kw = d1c5db3 merged ok, testing candidate = dc65307

@bors
Copy link
Contributor

@bors bors commented on d1c5db3 Aug 17, 2014

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fast-forwarding master to auto = dc65307

Please sign in to comment.