Skip to content

Commit 0ba90a4

Browse files
committed
update
1 parent 7f415b3 commit 0ba90a4

File tree

5 files changed

+92
-7
lines changed

5 files changed

+92
-7
lines changed

CHANGELOG.md

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,36 @@
22

33
[中文Log](CHANGELOG_CN.md)
44

5+
## [0.9.28] - 2025-8-22
6+
7+
### 🐛 Fixed
8+
- **Crash issue fixed**: Fixed a crash caused by parsing Unicode characters in comments.
9+
- **Large table performance issue fixed**: Fixed a performance issue where parsing large array tables in projects caused severe slowdowns.
10+
- **Generic type matching fixed**: Fixed an issue with incorrect matching of `constTpl<T>` types affecting generic type hints.
11+
12+
### ✨ Added
13+
- **Markdown syntax highlighting enabled by default**: Markdown syntax highlighting in comments is now enabled by default, including partial syntax highlighting for code blocks within comments.
14+
- **Support for `@language`**: Added support for using `@language` in comments to specify the language of code blocks, for example:
15+
```lua
16+
---@language lua
17+
local d = [[
18+
print("Hello, world!")
19+
]]
20+
```
21+
This enables syntax highlighting for Lua code.
22+
23+
- **Support for `Language<T>` generic type**: You can now use `Language<T: string>` in parameter comments to specify the language of a parameter, for example:
24+
```lua
25+
---@param lang Language<"vim">
26+
function vim_run(lang)
27+
end
28+
29+
vim_run [[set ft=lua]]
30+
```
31+
Supported injected languages: lua, vim, sql, json, shell, protobuf.
32+
33+
- **Support for `keyof type`**: When a function parameter is `keyof type`, corresponding code completion is provided.
34+
535
## [0.9.27] - 2025-8-8
636

737
### 🐛 Fixed

CHANGELOG_CN.md

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,35 @@
11
# 🚀 Change Log
22

3+
## [0.9.28] - 2025-8-22
4+
5+
### 🐛 问题修复
6+
- **崩溃问题修复**:修复了解析注释中的 Unicode 字符导致的崩溃问题。
7+
- **大型表性能问题修复**:修复了解析项目中大型数组表时导致严重性能下降的问题。
8+
- **泛型类型匹配修复**:修复了 `constTpl<T>` 类型匹配错误影响泛型类型提示的问题。
9+
10+
### ✨ 新增功能
11+
- **Markdown 语法高亮默认启用**:注释中的 Markdown 语法高亮现已默认启用,包括对注释内代码块的部分语法高亮。
12+
- **支持 `@language`**:新增对注释中使用 `@language` 指定代码块语言的支持,例如:
13+
```lua
14+
---@language lua
15+
local d = [[
16+
print("Hello, world!")
17+
]]
18+
```
19+
可为 Lua 代码块启用语法高亮。
20+
21+
- **支持 `Language<T>` 泛型类型**:现在可在参数注释中使用 `Language<T: string>` 指定参数语言,例如:
22+
```lua
23+
---@param lang Language<"vim">
24+
function vim_run(lang)
25+
end
26+
27+
vim_run [[set ft=lua]]
28+
```
29+
支持注入的语言包括:lua、vim、sql、json、shell、protobuf。
30+
31+
- **支持 `keyof type`**:当函数参数为 `keyof type` 时,提供对应的代码补全。
32+
333
## [0.9.27] - 2025-8-8
434

535
### 🐛 问题修复

build/config.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
exports.default = {
2-
emmyDebuggerVersion: '1.8.6',
2+
emmyDebuggerVersion: '1.8.7',
33
emmyDebuggerUrl: 'https://github.com/EmmyLua/EmmyLuaDebugger/releases/download',
4-
newLanguageServerVersion: "0.11.0",
4+
newLanguageServerVersion: "0.12.0",
55
newLanguageServerUrl: "https://github.com/CppCXY/emmylua-analyzer-rust/releases/download"
66
}

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"name": "emmylua",
33
"displayName": "EmmyLua",
44
"description": "EmmyLua for vscode",
5-
"version": "0.9.27",
5+
"version": "0.9.28",
66
"icon": "res/icon.png",
77
"publisher": "tangzx",
88
"engines": {

syntaxes/schema.json

Lines changed: 29 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@
5151
"default": {
5252
"knownTags": [],
5353
"privateName": [],
54-
"syntax": "none"
54+
"syntax": "md"
5555
}
5656
},
5757
"documentColor": {
@@ -118,14 +118,15 @@
118118
"nonstandardSymbol": [],
119119
"requireLikeFunction": [],
120120
"requirePattern": [],
121+
"special": {},
121122
"version": "LuaLatest"
122123
}
123124
},
124125
"semanticTokens": {
125126
"$ref": "#/$defs/EmmyrcSemanticToken",
126127
"default": {
127128
"enable": true,
128-
"renderDocumentationMarkup": false
129+
"renderDocumentationMarkup": true
129130
}
130131
},
131132
"signature": {
@@ -417,6 +418,11 @@
417418
"description": "enum-value-mismatch",
418419
"type": "string",
419420
"const": "enum-value-mismatch"
421+
},
422+
{
423+
"description": "preferred-local-alias",
424+
"type": "string",
425+
"const": "preferred-local-alias"
420426
}
421427
]
422428
},
@@ -640,7 +646,7 @@
640646
"syntax": {
641647
"description": "Syntax for highlighting documentation.",
642648
"$ref": "#/$defs/DocSyntax",
643-
"default": "none"
649+
"default": "md"
644650
}
645651
}
646652
},
@@ -949,6 +955,14 @@
949955
"type": "string"
950956
}
951957
},
958+
"special": {
959+
"description": "Special symbols.",
960+
"type": "object",
961+
"additionalProperties": {
962+
"$ref": "#/$defs/EmmyrcSpecialSymbol"
963+
},
964+
"default": {}
965+
},
952966
"version": {
953967
"description": "Lua version.",
954968
"$ref": "#/$defs/EmmyrcLuaVersion",
@@ -983,6 +997,17 @@
983997
}
984998
}
985999
},
1000+
"EmmyrcSpecialSymbol": {
1001+
"type": "string",
1002+
"enum": [
1003+
"none",
1004+
"require",
1005+
"error",
1006+
"assert",
1007+
"type",
1008+
"setmetatable"
1009+
]
1010+
},
9861011
"EmmyrcStrict": {
9871012
"type": "object",
9881013
"properties": {
@@ -1097,4 +1122,4 @@
10971122
]
10981123
}
10991124
}
1100-
}
1125+
}

0 commit comments

Comments
 (0)