Skip to content

Commit 1863d0e

Browse files
committed
completion can triggered in LuaDoc and string
1 parent 25c8a89 commit 1863d0e

File tree

3 files changed

+40
-4
lines changed

3 files changed

+40
-4
lines changed

package.json

Lines changed: 22 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1082,6 +1082,22 @@
10821082
"scope": "resource",
10831083
"type": "integer"
10841084
},
1085+
"Lua.hint.arrayIndex": {
1086+
"default": "Auto",
1087+
"enum": [
1088+
"Enable",
1089+
"Auto",
1090+
"Disable"
1091+
],
1092+
"markdownDescription": "%config.hint.arrayIndex%",
1093+
"markdownEnumDescriptions": [
1094+
"%config.hint.arrayIndex.Enable%",
1095+
"%config.hint.arrayIndex.Auto%",
1096+
"%config.hint.arrayIndex.Disable%"
1097+
],
1098+
"scope": "resource",
1099+
"type": "string"
1100+
},
10851101
"Lua.hint.enable": {
10861102
"default": false,
10871103
"markdownDescription": "%config.hint.enable%",
@@ -1510,7 +1526,12 @@
15101526
{
15111527
"language": "lua",
15121528
"path": "./syntaxes/lua.tmLanguage.json",
1513-
"scopeName": "source.lua"
1529+
"scopeName": "source.lua",
1530+
"tokenTypes": {
1531+
"comment.line.double-dash.doc.lua": "other",
1532+
"string.quoted.double.lua": "other",
1533+
"string.quoted.single.lua": "other"
1534+
}
15141535
}
15151536
],
15161537
"semanticTokenScopes": [

package/package.lua

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,12 @@ return {
3939
{
4040
language = "lua",
4141
scopeName = "source.lua",
42-
path = "./syntaxes/lua.tmLanguage.json"
42+
path = "./syntaxes/lua.tmLanguage.json",
43+
tokenTypes = {
44+
["comment.line.double-dash.doc.lua"] = "other",
45+
["string.quoted.single.lua"] = "other",
46+
["string.quoted.double.lua"] = "other",
47+
},
4348
}
4449
},
4550
semanticTokenScopes = {

syntaxes/lua.tmLanguage.json

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -364,19 +364,29 @@
364364
"name": "comment.line.double-dash.lua"
365365
},
366366
{
367-
"begin": "---?",
367+
"begin": "---",
368368
"beginCaptures": {
369369
"0": {
370370
"name": "punctuation.definition.comment.lua"
371371
}
372372
},
373373
"end": "\\n",
374-
"name": "comment.line.double-dash.lua",
374+
"name": "comment.line.double-dash.doc.lua",
375375
"patterns": [
376376
{
377377
"include": "#luadoc"
378378
}
379379
]
380+
},
381+
{
382+
"begin": "--",
383+
"beginCaptures": {
384+
"0": {
385+
"name": "punctuation.definition.comment.lua"
386+
}
387+
},
388+
"end": "\\n",
389+
"name": "comment.line.double-dash.lua"
380390
}
381391
]
382392
},

0 commit comments

Comments
 (0)