|
201 | 201 | "name": "punctuation.definition.string.begin.lua" |
202 | 202 | } |
203 | 203 | }, |
204 | | - "end": "'", |
| 204 | + "end": "'[ \\t]*", |
205 | 205 | "endCaptures": { |
206 | 206 | "0": { |
207 | 207 | "name": "punctuation.definition.string.end.lua" |
|
221 | 221 | "name": "punctuation.definition.string.begin.lua" |
222 | 222 | } |
223 | 223 | }, |
224 | | - "end": "\"", |
| 224 | + "end": "\"[ \\t]*", |
225 | 225 | "endCaptures": { |
226 | 226 | "0": { |
227 | 227 | "name": "punctuation.definition.string.end.lua" |
|
245 | 245 | } |
246 | 246 | }, |
247 | 247 | "contentName": "meta.embedded.lua", |
248 | | - "end": "(\\]\\2\\])", |
| 248 | + "end": "(\\]\\2\\])[ \\t]*", |
249 | 249 | "endCaptures": { |
250 | 250 | "0": { |
251 | 251 | "name": "string.quoted.other.multiline.lua" |
|
267 | 267 | "name": "punctuation.definition.string.begin.lua" |
268 | 268 | } |
269 | 269 | }, |
270 | | - "end": "\\]\\1\\]", |
| 270 | + "end": "\\]\\1\\][ \\t]*", |
271 | 271 | "endCaptures": { |
272 | 272 | "0": { |
273 | 273 | "name": "punctuation.definition.string.end.lua" |
|
410 | 410 | "begin": "\\b([a-zA-Z_][a-zA-Z0-9_]*)\\b", |
411 | 411 | "beginCaptures": { |
412 | 412 | "0": { |
413 | | - "name": "variable.lua" |
| 413 | + "name": "entity.name.variable.lua" |
414 | 414 | } |
415 | 415 | }, |
416 | 416 | "end": "(?=\\n)", |
|
421 | 421 | ] |
422 | 422 | } |
423 | 423 | ] |
| 424 | + }, |
| 425 | + { |
| 426 | + "begin": "@return", |
| 427 | + "beginCaptures": { |
| 428 | + "0": { |
| 429 | + "name": "storage.type.annotation.lua" |
| 430 | + } |
| 431 | + }, |
| 432 | + "end": "(?=\\n)", |
| 433 | + "patterns": [ |
| 434 | + { |
| 435 | + "include": "#luadoc.type" |
| 436 | + } |
| 437 | + ] |
424 | 438 | } |
425 | 439 | ] |
426 | 440 | }, |
427 | 441 | "luadoc.type": { |
| 442 | + "begin": "(?=[a-zA-Z_\\.\"])", |
| 443 | + "end": "(?=\\s)", |
428 | 444 | "patterns": [ |
429 | 445 | { |
430 | | - "match": "\\b([a-zA-Z_][a-zA-Z0-9_\\.]*)\\b", |
| 446 | + "match": "(\\b([a-zA-Z_][a-zA-Z0-9_\\.]*)\\b)[ \\t]*", |
431 | 447 | "name": "support.type.lua" |
432 | 448 | }, |
433 | 449 | { |
434 | | - "match": "\\|", |
| 450 | + "include": "#string" |
| 451 | + }, |
| 452 | + { |
| 453 | + "include": "#luadoc.type.resume" |
| 454 | + } |
| 455 | + ] |
| 456 | + }, |
| 457 | + "luadoc.type.resume": { |
| 458 | + "begin": "\\|", |
| 459 | + "beginCaptures": { |
| 460 | + "0": { |
435 | 461 | "name": "keyword.operator.lua" |
| 462 | + } |
| 463 | + }, |
| 464 | + "end": "(?=\\s)", |
| 465 | + "patterns": [ |
| 466 | + { |
| 467 | + "match": "(\\b([a-zA-Z_][a-zA-Z0-9_\\.]*)\\b)[ \\t]*", |
| 468 | + "name": "support.type.lua" |
436 | 469 | }, |
437 | 470 | { |
438 | 471 | "include": "#string" |
| 472 | + }, |
| 473 | + { |
| 474 | + "include": "#luadoc.type.resume" |
439 | 475 | } |
440 | 476 | ] |
441 | 477 | } |
|
0 commit comments