Skip to content

Commit fde58d9

Browse files
committed
auto merge of #16231 : michaelsproul/rust/gedit-macro, r=alexcrichton
Gedit currently lacks syntax highlighting for macros.
2 parents 157459b + 806e4f0 commit fde58d9

File tree

1 file changed

+8
-0
lines changed
  • src/etc/gedit/share/gtksourceview-3.0/language-specs

1 file changed

+8
-0
lines changed

src/etc/gedit/share/gtksourceview-3.0/language-specs/rust.lang

+8
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@
2222
<style id="number" _name="Number" map-to="def:number"/>
2323
<style id="scope" _name="Scope" map-to="def:preprocessor"/>
2424
<style id="attribute" _name="Attribute" map-to="def:preprocessor"/>
25+
<style id="macro" _name="Macro" map-to="def:preprocessor"/>
2526
</styles>
2627

2728
<definitions>
@@ -251,6 +252,12 @@
251252
</match>
252253
</context>
253254

255+
<context id="macro" style-ref="macro">
256+
<match extended="true">
257+
\%{ident}!
258+
</match>
259+
</context>
260+
254261
<context id="lifetime" style-ref="keyword">
255262
<match extended="true">
256263
'\%{ident}
@@ -308,6 +315,7 @@
308315
<context ref="types"/>
309316
<context ref="ctypes"/>
310317
<context ref="self"/>
318+
<context ref="macro"/>
311319
<context ref="constants"/>
312320
<context ref="cconstants"/>
313321
<context ref="line-comment"/>

0 commit comments

Comments
 (0)