Skip to content

Commit 0d4207f

Browse files
rust: className -> scope
Co-authored-by: Josh Goebel <[email protected]>
1 parent e1360be commit 0d4207f

File tree

1 file changed

+11
-11
lines changed

1 file changed

+11
-11
lines changed

src/languages/rust.js

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ export default function(hljs) {
1717
const IDENT_RE = regex.concat(RAW_IDENTIFIER, hljs.IDENT_RE);
1818
// ============================================
1919
const FUNCTION_INVOKE = {
20-
className: "title.function.invoke",
20+
scope: "title.function.invoke",
2121
relevance: 0,
2222
begin: regex.concat(
2323
/\b/,
@@ -199,7 +199,7 @@ export default function(hljs) {
199199
illegal: null
200200
}),
201201
{
202-
className: 'symbol',
202+
scope: 'symbol',
203203
// negative lookahead to avoid matching `'`
204204
begin: /'[a-zA-Z_][a-zA-Z0-9_]*(?!')/
205205
},
@@ -220,7 +220,7 @@ export default function(hljs) {
220220
]
221221
},
222222
{
223-
className: 'number',
223+
scope: 'number',
224224
variants: [
225225
{ begin: '\\b0b([01_]+)' + NUMBER_SUFFIX },
226226
{ begin: '\\b0o([0-7_]+)' + NUMBER_SUFFIX },
@@ -236,18 +236,18 @@ export default function(hljs) {
236236
/\s+/,
237237
UNDERSCORE_IDENT_RE
238238
],
239-
className: {
239+
scope: {
240240
1: "keyword",
241241
3: "title.function"
242242
}
243243
},
244244
{
245-
className: 'meta',
245+
scope: 'meta',
246246
begin: '#!?\\[',
247247
end: '\\]',
248248
contains: [
249249
{
250-
className: 'string',
250+
scope: 'string',
251251
begin: /"/,
252252
end: /"/,
253253
contains: [
@@ -263,7 +263,7 @@ export default function(hljs) {
263263
/(?:mut\s+)?/,
264264
UNDERSCORE_IDENT_RE
265265
],
266-
className: {
266+
scope: {
267267
1: "keyword",
268268
3: "keyword",
269269
4: "variable"
@@ -278,7 +278,7 @@ export default function(hljs) {
278278
/\s+/,
279279
/in/
280280
],
281-
className: {
281+
scope: {
282282
1: "keyword",
283283
3: "variable",
284284
5: "keyword"
@@ -290,7 +290,7 @@ export default function(hljs) {
290290
/\s+/,
291291
UNDERSCORE_IDENT_RE
292292
],
293-
className: {
293+
scope: {
294294
1: "keyword",
295295
3: "title.class"
296296
}
@@ -301,7 +301,7 @@ export default function(hljs) {
301301
/\s+/,
302302
UNDERSCORE_IDENT_RE
303303
],
304-
className: {
304+
scope: {
305305
1: "keyword",
306306
3: "title.class"
307307
}
@@ -315,7 +315,7 @@ export default function(hljs) {
315315
}
316316
},
317317
{
318-
className: "punctuation",
318+
scope: "punctuation",
319319
begin: '->'
320320
},
321321
FUNCTION_INVOKE

0 commit comments

Comments
 (0)