2024-11-13
FIX
Incorrect type check in some case
2024-11-13
NEW
Setting:Lua.type.inferTableSize
: A Small Table array can be inferedNEW
Add custom repository support for addonManager. New configuration setting:Lua.addonManager.repositoryBranch
andLua.addonManager.repositoryPath
NEW
Infer function parameter types when the function is used as an callback argument and that argument has afun()
annotation. Enable withLua.type.inferParamType
setting. #2695---@param callback fun(a: integer) function register(callback) end local function callback(a) end --> a: integer register(callback)
CHG
Basic types allow contravariance---@class int32: integer ---@type integer local n ---@type int32 local a = n
FIX
Improve type narrow with literal alias type during completion and signature help
2024-10-30
NEW
Support importingenum
through class name suffix matching in quick fixes, allowing the import ofenum
fromtable.table.enum; return table
.NEW
Support limited multiline annotations---@type { --- x: number, --- y: number, --- z: number, ---} local point --> local point: { x: number, y: number, z: number }
FIX
A regression related to type narrow and generic param introduced sincev3.10.1
FIX
Parse storagePath to improve reliability of resolving ${addons} placeholderFIX
Reference should also look in tablefieldFIX
Determine that the index of{...}
is an integer when iterating
2024-10-9
FIX
Fixed an issue preventing to set the locale to JapaneseFIX
Preserve newlines between function comment and @seeFIX
Accept storagePath option from client to resolve addon directory not found
2024-9-30
NEW
Added support for Japanese localeNEW
Infer function parameter types when overriding the same-named class function in an instance of that class #2158NEW
Types with literal fields can be narrowed.NEW
Reference addons installed via the addon manager with${addons}
#2866.NEW
Support using---@class
onrawset(_G, ...)
to annotate the created global variable #2862NEW
Settings:Lua.language.fixIndent
Lua.language.completeAnnotation
FIX
Eliminate floating point error in test benchmark outputFIX
Remove luamake install from make scriptsFIX
Incorrecttable
type injected to the global variable created byrawset(_G, ...)
#2863
2024-9-10
NEW
Custom documentation exporterNEW
Setting:Lua.docScriptPath
: Path to a script that overridescli.doc.export
, allowing user-specified documentation exporting.NEW
Infer the parameter types of a same-named function in the subclass based on the parameter types in the superclass function.FIX
FixVM.OnCompileFunctionParam
function in pluginsFIX
Lua 5.1: fix incorrect warning when using setfenv with an int as first parameterFIX
Improve type narrow by checking exact match on literal type paramsFIX
Correctly list enums for function overload arguments #2840FIX
Incorrect function params' type infer when there is only@overload
#2509 #2708 #2709FIX
Only call workspace/configuration when available #981, #2318, 2336 #2843
2024-8-19
NEW
usingenum (partial)
, it suggests all fields with the sameenum
type rather than just the fields from the current table.NEW
When usingenum["<key>" or <index>]
, undefined fields will raise an 'undefined' error.FIX
Renaming files in the directory leads to the auto-correction in "require" adding extra characters.FIX
Performance issueFIX
Fix incorrect indent fixing forfor
2024-8-16
NEW
Setting:Lua.type.checkTableShape
: Add matching checks between the shape of tables and classes, during type checking. #2768NEW
undefined-field
supportsenum
CHG
Show enumed table asenum X
instead oftable
FIX
Errorattempt to index a nil value
whenLua.hint.semicolon == 'All'
#2788FIX
Incorrect LuaCats parsing for"'"
FIX
Incorrect indent fixings
2024-8-8
FIX
Memory leak with---@enum(partical)
2024-8-7
NEW
Add support for binary metamethod on right operand #2777FIX
Incorrect indentation fixing in some case
2024-8-2
FIX
Runtime errorFIX
Disable indentation fixing for Non-VSCode
2024-8-1
NEW
Add postfix snippet forunpack
NEW
Add support for lambda style functions,|paramList| expr
is syntactic sugar forfunction(paramList) return expr end
NEW
Added lua regular expression support forLua.doc.<scope>Name
#2753NEW
You can now click on "References" in CodeLen to display the reference list(VSCode)NEW
Improved behavior for inserting new lines:- When inside an annotation, an annotation tag will be added at the beginning of the line (VSCode).
- When between
function () end
or similar constructs, the format will be adjusted to a more reasonable one (VSCode) and leading/trailing spaces will be removed (generic). - Attempts to semantically fix improper indentation (generic).
CHG
Improve performance of multithreaded--check
andundefined-field
diagnosticCHG
Change spacing of parameter inlay hints to match other LSPs, likerust-analyzer
FIX
diagnostics.severity
defaulting to "Warning" when run using--check
#2730FIX
Respectcompletion.showParams
config for local function completionFIX
Addons can now self-recommend as expected. Fixed by correcting thewholeMatch
functionFIX
Now correctly evaluates the visibility of fields in a class when they are defined directly in the object. use for completion and invisible dianostic. #2752FIX
Bad triggering of theinject-field
diagnostic, when the fields are declared at the creation of the object #2746FIX
Inconsistent type narrow behavior of function call args #2758FIX
Improve themissing-fields
logic to be able to correctly handle classes defined several times #22770FIX
Typos in annotation descriptionsFIX
incorrectCompletionItemKind
for postfix snippets #2773
2024-6-11
FIX
Sometimes providing incorrect autocompletion when chaining calls
2024-6-6
NEW
Reference workspace symbols in comments using[some text](lua://symbolName)
syntaxFIX
Don't do diagnostics when the workspace is not readyFIX
Autocompletion for enum values is not available in some cases
2024-5-14
- revert extension runtime
2024-5-11
NEW
goto implementationNEW
narrow the function prototype based on the parameter type---@overload fun(a: boolean): A ---@overload fun(a: number): B local function f(...) end local r1 = f(true) --> r1 is `A` local r2 = f(10) --> r2 is `B`
2024-4-23
FIX
server may crash when the workspace is using a non-English path.
2024-4-23
- This is a fake version only for the new version of VSCode, with a core of 3.8.0.
2024-4-23
- This is a fake version only for the old version of VSCode, with a core of
3.7.4
. Starting from the next minor version, the version requirement for VSCode will be raised to prevent users still using the old version of VSCode from updating to the new version and experiencing compatibility issues.
2024-4-22
-
NEW
supports tuple type (@lizho)---@type [string, number, boolean] local t local x = t[1] --> x is `string` local y = t[2] --> y is `number` local z = t[3] --> z is `boolean`
-
NEW
generic pattern (@fesily)---@generic T ---@param t Cat.`T` ---@return T local function f(t) end local t = f('Smile') --> t is `Cat.Smile`
-
NEW
alias and enums supports attributepartial
---@alias Animal Cat ---@alias(partial) Animal Dog ---@type Animal local animal --> animal is `Cat|Dog` here
---@enum(key) ErrorCodes local codes1 = { OK = 0, ERROR = 1, FATAL = 2, } ---@enum(key, partial) ErrorCodes local codes2 = { WARN = 3, INFO = 4, } ---@type ErrorCodes local code code = 'ERROR' --> OK code = 'WARN' --> OK
-
NEW
plugin: addOnTransFormAst
interface (@fesily) -
NEW
plugin: addOnNodeCompileFunctionParam
interface (@fesily) -
NEW
plugin: addResolveRequire
interface (@Artem Dzhemesiuk) -
NEW
plugin: support multi plugins (@fesily)- setting:
Lua.runtime.plugin
can bestring|string[]
- setting:
Lua.runtime.pluginArgs
can bestring[]|table<string, string>
- setting:
-
NEW
CLI:--doc
add option--doc_out_path <PATH>
(@Andreas Matthias) -
NEW
CLI:--doc_update
, update an existingdoc.json
without using--doc
again (@Andreas Matthias) -
NEW
CLI:--trust_all_plugins
, this is potentially unsafe for normal use and meant for usage in CI environments only (@Paul Emmerich) -
CHG
CLI:--check
will run plugins (@Daniel Farrell) -
FIX
diagnostic:discard-returns
not works in some blocks (@clay-golem) -
FIX
rename in library files
2024-1-5
FIX
rename to unicode withLua.runtime.unicodeName = true
2023-11-14
FIX
can not infer arg type in some cases.
2023-11-9
FIX
#2407
2023-11-7
2023-8-24
-
NEW
support---@type
and--[[@as]]
for return statement -
NEW
commandline parameter--force-accept-workspace
: allowing the use of the root directory or home directory as the workspace -
NEW
diagnostic:inject-field
-
NEW
---@enum
supports attributekey
---@enum (key) AnimalType local enum = { Cat = 1, Dog = 2, } ---@param animal userdata ---@param atp AnimalType ---@return boolean local function isAnimalType(animal, atp) return API.isAnimalType(animal, enum[atp]) end assert(isAnimalType(animal, 'Cat'))
-
NEW
---@class
supports attributeexact
---@class (exact) Point ---@field x number ---@field y number local m = {} m.x = 1 -- OK m.y = 2 -- OK m.z = 3 -- Warning
-
FIX
wrong hover and signature for method with varargs and overloads -
FIX
#2155 -
FIX
#2224 -
FIX
#2252 -
FIX
#2267
2023-7-26
FIX
#2214
2023-7-21
NEW
diagnostic:missing-fields
FIX
shake ofcodeLens
FIX
#2145
2023-7-7
CHG
signature: narrow by inputed literal
2023-6-14
2023-5-24
FIX
disable ffi plugin
2023-5-23
NEW
support connecting by socket with--socket=PORT
FIX
#2113
2023-4-26
2023-3-23
2023-3-9
CHG
export documents: export global variablesFIX
#1715FIX
#1753FIX
#1914FIX
#1922FIX
#1924FIX
#1928FIX
#1945FIX
#1955FIX
#1978
2023-3-2
FIX
setting:Lua.addonManager.enable
should betrue
by defaultFIX
failed to publish to Windows
2023-3-2
NEW
Addon Manager, try it with commandlua.addon_manager.open
. Thanks to carsakiller!
2023-2-13
2023-2-7
2023-2-2
2023-1-31
NEW
commandlua.exportDocument
. VSCode will display this command in the right-click menuCHG
settingLua.workspace.supportScheme
has been removed. All schemes are supported if the language id islua
FIX
#1831FIX
#1838FIX
#1841FIX
#1851FIX
#1855FIX
#1857
2023-1-20
2023-1-17
2023-1-16
NEW
support casting global variablesNEW
code lens: this feature is disabled by default.NEW
settings:Lua.codeLens.enable
: Enable code lens.
CHG
improve memory usage for large librariesCHG
definition: supports finding definitions for@class
and@alias
, since they may be defined multi timesCHG
rename: supports@field
CHG
improve patch for.luarc.json
CHG
---@meta [name]
: once declaredname
, user can only require this file by declared name. meta file can not be required with name_
CHG
remove telemetryFIX
#831FIX
#1729FIX
#1737FIX
#1751FIX
#1767FIX
#1796FIX
#1805FIX
#1808FIX
#1811FIX
#1824
2022-11-29
NEW
modifyrequire
after renaming filesFIX
circulation reference in process analysis---@type number local x ---@type number local y x = y y = x --> Can not infer `y` before
FIX
#1698FIX
#1704FIX
#1717
2022-11-14
2022-11-10
2022-11-8
FIX
wrong diagnostics forpcall
andxpcall
FIX
duplicate fields in table hoverFIX
description disapeared for overloaded functionFIX
#1675
2022-11-8
NEW
supportsprivate
/protected
/public
/package
- mark in
doc.field
---@class unit ---@field private uuid integer
- mark with
---@private
,---@protected
,---@public
and---@package
---@class unit local mt = {} ---@private function mt:init() end ---@protected function mt:update() end
- mark by settings
Lua.doc.privateName
,Lua.doc.protectedName
andLua.doc.packageName
---@class unit ---@field _uuid integer --> treat as private when `Lua.doc.privateName` has `"_*"`
- mark in
NEW
settings:Lua.misc.executablePath
: #1557 specify the executable path in VSCodeLua.diagnostics.workspaceEvent
: #1626 set the time to trigger workspace diagnostics.Lua.doc.privateName
: treat matched fields as privateLua.doc.protectedName
: treat matched fields as protectedLua.doc.packageName
: treat matched fields as package
NEW
CLI--doc [path]
to make docs. server will generatedoc.json
anddoc.md
inLOGPATH
.doc.md
is generated bydoc.json
by example codescript/cli/doc2md.lua
.CHG
#1558 detect multi librariesCHG
#1458semantic-tokens
: global variable is setted tovariable.global
// color global variables to red "editor.semanticTokenColorCustomizations": { "rules": { "variable.global": "#ff0000" } }
CHG
#1177 re-support for symlinks, users need to maintain the correctness of symlinks themselvesCHG
#1561 infer definitions and types across chain expression---@class myClass local myClass = {} myClass.a.b.c.e.f.g = 1 ---@type myClass local class print(class.a.b.c.e.f.g) --> inferred as integer
CHG
#1582 the following diagnostics consideroverload
missing-return
missing-return-value
redundant-return-value
return-type-mismatch
CHG
workspace-symbol: supports chain fields based on global variables and types. tryio.open
oriolib.open
CHG
#1641 if a function only has varargs and has---@overload
, the varargs will be ignoredCHG
#1575 search definitions by first argument ofsetmetatable
---@class Object local obj = setmetatable({ initValue = 1, }, mt) print(obj.initValue) --> `obj.initValue` is integer
CHG
#1153 infer type by generic parameters or returns of function---@generic T ---@param f fun(x: T) ---@return T[] local function x(f) end ---@type fun(x: integer) local cb local arr = x(cb) --> `arr` is inferred as `integer[]`
CHG
#1201 infer parameter type by expected returned function of parent function---@return fun(x: integer) local function f() return function (x) --> `x` is inferred as `integer` end end
CHG
#1332 infer parameter type when function in table---@class A ---@field f fun(x: string) ---@type A local t = { f = function (x) end --> `x` is inferred as `string` }
CHG
find reference: respectincludeDeclaration
(although I don't know how to turn off this option in VSCode)CHG
#1344 improve---@see
CHG
#1484 settingruntime.special
supports fields{ "runtime.special": { "sandbox.require": "require" } }
CHG
#1533 supports completion with table field of functionCHG
#1457 infer parameter type by function type---@type fun(x: number) local function f(x) --> `x` is inferred as `number` end
CHG
#1663 check parameter types of generic extends---@generic T: string | boolean ---@param x T ---@return T local function f(x) return x end local x = f(1) --> Warning: Cannot assign `integer` to parameter `<T:boolean|string>`.
CHG
#1434 type check: check the fields in table:---@type table<string, string> local x ---@type table<string, number> local y x = y --> Warning: Cannot assign `<string, number>` to `<string, string>`
CHG
#1374 type check: supports array part in literal table---@type boolean[] local t = { 1, 2, 3 } --> Warning: Cannot assign `integer` to `boolean`
CHG
---@enum
supports runtime valuesFIX
#1479FIX
#1480FIX
#1567FIX
#1593FIX
#1595FIX
#1599FIX
#1606FIX
#1608FIX
#1637FIX
#1640FIX
#1642FIX
#1662FIX
#1672
2022-9-16
2022-9-7
2022-9-6
NEW
type-formatting
: fix wrong indentation of VSCodeCHG
document-symbol
: redesigned to better support forSticky Scroll
feature of VSCodeFIX
diagnostics.workspaceDelay
can not prevent first workspace diagnosticFIX
#1476FIX
#1490FIX
#1493FIX
#1499FIX
#1526
2022-8-13
2022-8-1
2022-7-26
NEW
supports colorNEW
settingLua.runtime.pluginArgs
CHG
settingtype.castNumberToInteger
default bytrue
CHG
improve supports for multi-workspaceFIX
#1354FIX
#1355FIX
#1363FIX
#1365FIX
#1367FIX
#1368FIX
#1370FIX
#1375FIX
#1391
2022-7-19
NEW
LuaDoc
:---@operator
:---@class fspath ---@operator div(string|fspath): fspath ---@type fspath local root local fileName = root / 'script' / 'main.lua' -- `fileName` is `fspath` here
NEW
LuaDoc
:---@source
:-- Also supports absolute path or relative path (based on current file path) ---@source file:///xxx.c:50:20 XXX = 1 -- when finding definitions of `XXX`, returns `file:///xxx.c:50:20` instead here.
NEW
LuaDoc
:---@enum
:---@enum animal Animal = { Cat = 1, Dog = 2, } ---@param x animal local function f(x) end f() -- suggests `Animal.Cat`, `Animal.Dog`, `1`, `2` as the first parameter
NEW
diagnostics:unknown-operator
unreachable-code
NEW
settings:diagnostics.unusedLocalExclude
NEW
VSCode: add support for EmmyLuaUnityCHG
support multi-type:---@type number, _, boolean local a, b, c -- `a` is `number`, `b` is `unknown`, `c` is `boolean`
CHG
treat_ENV = XXX
aslocal _ENV = XXX
_ENV = nil
: disable all globals_ENV = {}
: allow all globals_ENV = {} ---@type mathlib
: only allow globals inmathlib
CHG
hover: dose not show unknown---@XXX
as descriptionCHG
contravariance is allowed at the class declaration---@class BaseClass local BaseClass ---@class MyClass: BaseClass local MyClass = BaseClass -- OK!
CHG
hover: supports path in link--![](image.png) --> will convert to `--![](file:///xxxx/image.png)` local x
CHG
signature: only show signatures matching the entered parametersFIX
#880FIX
#1284FIX
#1292FIX
#1294FIX
#1306FIX
#1311FIX
#1317FIX
#1320FIX
#1330FIX
#1345FIX
#1346FIX
#1348
2022-7-6
CHG
diagnostic:type-check
ignoresnil
ingetfield
CHG
diagnostic:---@diagnostic disable: <ERR_NAME>
can suppress syntax errorsCHG
completion:completion.callSnippet
no longer generate parameter typesCHG
hover: show---@type {x: number, y: number}
as detail instead oftable
CHG
dose not infer asnil
byt.field = nil
FIX
#1278FIX
#1288
2022-7-5
NEW
settings:type.weakNilCheck
CHG
allow type contravariance forsetmetatable
when initializing a class---@class A local a = {} ---@class B: A local b = setmetatable({}, { __index = a }) -- OK!
FIX
#1256FIX
#1257FIX
#1267FIX
#1269FIX
#1273FIX
#1275FIX
#1279
2022-6-29
NEW
diagnostics:cast-local-type
assign-type-mismatch
param-type-mismatch
unknown-cast-variable
cast-type-mismatch
missing-return-value
redundant-return-value
missing-return
return-type-mismatch
NEW
settings:diagnostics.groupSeverity
diagnostics.groupFileStatus
type.castNumberToInteger
type.weakUnionCheck
hint.semicolon
CHG
infernil
as redundant return valuelocal function f() end local x = f() -- `x` is `nil` instead of `unknown`
CHG
infer called function by params num---@overload fun(x: number, y: number):string ---@overload fun(x: number):number ---@return boolean local function f() end local n1 = f() -- `n1` is `boolean` local n2 = f(0) -- `n2` is `number` local n3 = f(0, 0) -- `n3` is `string`
CHG
semicolons and parentheses can be used inDocTable
---@type { (x: number); (y: boolean) }
CHG
return names and parentheses can be used inDocFunction
---@type fun():(x: number, y: number, ...: number)
CHG
supports---@return boolean ...
CHG
improve experience for diagnostics and semantic-tokensFIX
diagnostics flash when opening a fileFIX
sometimes workspace diagnostics are not triggeredFIX
#1228FIX
#1229FIX
#1242FIX
#1243FIX
#1249
2022-6-17
2022-6-15
NEW
LuaDoc
supports`CODE`
---@type `CONST.X` | `CONST.Y` local x if x == -- suggest `CONST.X` and `CONST.Y` here
CHG
infer type byerror
---@type integer|nil local n if not n then error('n is nil') end print(n) -- `n` is `integer` here
CHG
infer type byt and t.x
---@type table|nil local t local s = t and t.x or 1 -- `t` in `t.x` is `table`
CHG
infer type bytype(x)
local x if type(x) == 'string' then print(x) -- `x` is `string` here end local tp = type(x) if tp == 'boolean' then print(x) -- `x` is `boolean` here end
CHG
infer type by>
/<
/>=
/<=
FIX
with clients that support LSP 3.17 (VSCode), workspace diagnostics are triggered every time when opening a file.FIX
#1204FIX
#1208
2022-6-9
2022-5-25
NEW
settings:workspace.supportScheme
:["file", "untitled", "git"]
diagnostics.disableScheme
:["git"]
NEW
folding: support folding---@alias
CHG
ifrootUri
orworkspaceFolder
is set toROOT
orHOME
, this extension will refuse to load these directories and show an error message.CHG
show warning message when scanning more than 100,000 files.CHG
upgrade LSP to3.17
FIX
hover: can not uniontable
with other basic typesFIX
#1125FIX
#1131FIX
#1134FIX
#1141FIX
#1144FIX
#1150FIX
#1155
2022-5-16
CHG
parse.luarc.json
as jsonc. In order to please the editor, it also supports.luarc.jsonc
as the file name.CHG
dose not load files in symbol linksFIX
memory leak with symbol linksFIX
diagnostic: send empty results to every file after startupFIX
#1103FIX
#1107
2022-4-26
FIX
diagnostic:unused-function
cannot handle recursion correctlyFIX
#1092FIX
#1093FIX
runtime errors reported by telemetry, see #1091
2022-4-25
FIX
broken in VSCode
2022-4-25
NEW
supports infer of callback parameter---@type string[] local t table.sort(t, function (a, b) -- `a` and `b` is `string` here end)
NEW
using---@overload
as class constructor---@class Class ---@overload fun():Class local mt local x = mt() --> x is `Class` here
NEW
add--[[@as type]]
local x = true local y = x--[[@as integer]] -- y is `integer` here
NEW
add---@cast
---@cast localname type
---@cast localname +type
---@cast localname -type
---@cast localname +?
---@cast localname -?
NEW
generic: resolveT[]
bytable<integer, type>
or---@field [integer] type
NEW
resolveclass[1]
by---@field [integer] type
NEW
diagnostic:missing-parameter
NEW
diagnostic:need-check-nil
CHG
diagnostic: no longer markredundant-parameter
asUnnecessary
FIX
diagnostic:unused-function
does not recognize recursionFIX
#1051FIX
#1072FIX
#1077FIX
#1088FIX
runtime errors
2022-4-17
NEW
support find definition in methodCHG
hint: move to LSP. Its font is now controlled by the client.CHG
hover: splitlocal
intolocal
/parameter
/upvalue
/self
.CHG
hover: added parentheses to some words, such asglobal
/field
/class
.FIX
definition oftable<k, v>
FIX
#994FIX
#1057FIX
runtime errors reported by telemetry, see #1058
2022-4-15
FIX
table<string, boolean>[string] -> boolean
FIX
gototype definition
FIX
#1050
2022-4-11
2022-4-10
CHG
break changesCHG
diagnostic:type-check
: removed for nowno-implicit-any
: renamed tono-unknown
CHG
formatter: no longer need--preview
CHG
LuaDoc
: supports---@type (string|integer)[]
FIX
semantic: color offunction
FIX
#1027FIX
#1028
2022-4-9
CHG
completion: call snippet shown asFunction
instead ofSnippet
whenLua.completion.callSnippet
isReplace
FIX
#976FIX
#995FIX
#1004FIX
#1008FIX
#1009FIX
#1011FIX
#1014FIX
#1016FIX
#1017FIX
runtime errors reported by telemetry
2022-3-9
NEW
diagnosis report, read moreCHG
VSCode
: 1.65 has built in newLua
syntax files, so this extension no longer provides syntax files, which means you can install other syntax extensions in the marketplace. If you have any suggestions or issues, please open issues here.CHG
telemetry: the prompt will only appear in VSCode to avoid repeated prompts in other platforms due to the inability to automatically modify the settings.FIX
#965FIX
#975
2022-2-21
2022-2-17
2022-2-9
CHG
completion: reduced sorting priority for postfix completionFIX
#936FIX
#937FIX
#940FIX
#941FIX
#941FIX
#943FIX
#946
2022-1-25
2022-1-25
FIX
#925
2022-1-24
CHG
default values of settings:Lua.diagnostics.workspaceDelay
:0
sec ->3
secLua.workspace.maxPreload
:1000
->5000
Lua.workspace.preloadFileSize
:100
KB ->500
KB
CHG
improve performanceFIX
modify luarc failedFIX
library files not recognized correctlyFIX
#903FIX
#906FIX
#920
2022-1-13
NEW
supports multi-workspace in server side, for developers of language clients, please read here to learn more.NEW
setting:Lua.hint.arrayIndex
Lua.semantic.enable
Lua.semantic.variable
Lua.semantic.annotation
Lua.semantic.keyword
CHG
completion: improve response speedCHG
completion: can be triggered inLuaDoc
and stringsCHG
diagnostic: smootherCHG
settingsLua.color.mode
removedFIX
#876FIX
#879FIX
#884FIX
#885FIX
#886FIX
#902
2021-12-27
CHG
diagnostic: now syntax errors inLuaDoc
are shown asWarning
FIX
#863FIX
return type ofmath.floor
FIX
runtime errors
2021-12-16
FIX
dose not work in VSCode
2021-12-16
2021-12-6
2021-12-2
2021-11-29
FIX
incorrect syntax error
2021-11-29
NEW
settings:Lua.runtime.pathStrict
: not check subdirectories when usingruntime.path
Lua.hint.await
: displayawait
when calling a function marked as asyncLua.completion.postfix
: the symbol that triggers postfix, default is@
NEW
add supports forlovr
NEW
file encoding supportsutf16le
andutf16be
NEW
full IntelliSense supports for literal tables, see #720 and #727NEW
LuaDoc
annotations:---@async
: mark a function as async---@nodiscard
: the return value of the marking function cannot be discarded
NEW
diagnostics:await-in-sync
: check whether calls async function in sync function. disabled by default.not-yieldable
: check whether the function supports async functions as parameters. disabled by default.discard-returns
: check whether the return value is discarded.
NEW
localept-br
, thanks Jeferson FerreiraNEW
supports utf-8-offsetsNEW
supports quickfix for.luarc.json
NEW
completion postifx:@function
,@method
,@pcall
,@xpcall
,@insert
,@remove
,@concat
,++
,++?
CHG
LuaDoc
:---@class
can be re-declared- supports unicode
- supports
---@param ... number
, equivalent to---@vararg number
- supports
fun(...: string)
- supports
fun(x, y, ...)
, equivalent tofun(x: any, y: any, ...: any)
CHG
settings from--configpath
,.luarc.json
,client
no longer prevent subsequent settings, instead they are merged in orderCHG
no longer asks to trust plugin in VSCode, because VSCode already provides the workspace trust featureCHG
skip huge files (>= 10 MB)CHG
after usingLua.runtime.nonstandardSymbol
to treat//
as a comment,//
is no longer parsed as an operator
2021-11-25
2021-11-23
2021-11-18
-
CHG
for performance reasons, some of the features that are not cost-effective in IntelliSense have been disabled by default, and you can re-enable them through the following settings:Lua.IntelliSense.traceLocalSet
Lua.IntelliSense.traceReturn
Lua.IntelliSense.traceBeSetted
Lua.IntelliSense.traceFieldInject
2021-11-15
2021-10-27
FIX
#762
2021-10-26
NEW
diagnostic:redundant-return
FIX
#744FIX
#748FIX
#749FIX
#752FIX
#753FIX
#756FIX
#758FIX
#760
2021-10-18
FIX
accidentally load lua files from user workspace
2021-10-15
CHG
improve.luarc.json
FIX
#722
2021-10-13
2021-10-8
2021-10-2
2021-10-1
NEW
loading settings from.luarc.json
NEW
settings:Lua.diagnostics.libraryFiles
Lua.diagnostics.ignoredFiles
Lua.completion.showWord
Lua.completion.requireSeparator
NEW
diagnostics:different-requires
NEW
---@CustomClass<string, number>
NEW
supports$/cancelRequest
NEW
EventEmitter
--- @class Emit --- @field on fun(eventName: string, cb: function) --- @field on fun(eventName: '"died"', cb: fun(i: integer)) --- @field on fun(eventName: '"won"', cb: fun(s: string)) local emit = {} emit:on(--[[support autocomplete fr "died" and "won"]]) emit:on("died", function (i) -- should be i: integer end) emit:on('won', function (s) -- should be s: string end)
NEW
---@module 'moduleName'
---@module 'mylib' local lib -- the same as `local lib = require 'mylib'`
NEW
add supports ofskynet
CHG
hover: improve showing multi definesCHG
hover: improve showing multi comments at enumsCHG
hover: shows methodCHG
hint:Lua.hint.paramName
now supportsDisable
,Literal
andAll
CHG
only search first file byrequire
CHG
no longer infer by usageCHG
no longer ignore file names case in WindowsCHG
watching library changesCHG
completion: improve misspelling resultsCHG
completion:Lua.completion.displayContext
default to0
CHG
completion:autoRequire
has better inserting positionCHG
diagnostics:redundant-parameter
default severity toWarning
redundant-value
default severity toWarning
CHG
infer: more strict of calculation resultsCHG
#663FIX
runtime errorsFIX
hint: may show param-2 asself
FIX
semantic: may fail when scrollingFIX
#647FIX
#660FIX
#673
2021-8-17
CHG
improve performanceFIX
#244
2021-8-9
FIX
completion: can not find global fieldsFIX
globals and class may lost
2021-8-9
CHG
improve memory usageCHG
completion: call snip triggers signature (VSCode only)FIX
completion: may not find results
2021-8-6
CHG
improve performanceFIX
#625
2021-7-26
2021-7-21
NEW
LuaDoc
: supports['string']
as field:---@class keyboard ---@field ['!'] number ---@field ['?'] number ---@field ['#'] number
NEW
add supports oflove2d
FIX
gitignore pattern\
broken initializationFIX
runtime errors
2021-7-19
NEW
settingLua.workspace.userThirdParty
, add private user third-parth by this settingCHG
path in config supports~/xxxx
FIX
autoRequire
inserted incorrect codeFIX
autoRequire
may provide dumplicated optionsFIX
#606FIX
#607
2021-7-16
NEW
VSCode
: click the status bar icon to operate:- run workspace diagnostics
NEW
LuaDoc
: supports[1]
as field:---@class position ---@field [1] number ---@field [2] number ---@field [3] number
NEW
hover: view arraylocal array = {'a', 'b', 'c'}
:local array: { [1]: string = "a", [2]: string = "b", [3]: string = "c", }
NEW
completion: supports enums infun()
---@type fun(x: "'aaa'"|"'bbb'") local f f(--[[show `'aaa'` and `'bbb'` here]])
FIX
loading workspace may hangFIX
debug.getuservalue
anddebug.setuservalue
should not exist inLua 5.1
FIX
infer of---@type class[][]
FIX
infer of---@type {}[]
FIX
completion: displaying@fenv
inLua 5.1
FIX
completion: incorrect at end of lineFIX
when a file is renamed, the file will still be loaded even if the new file name has been set to ignoreFIX
#596FIX
#597FIX
#598FIX
#601
2021-7-9
CHG
improveauto require
CHG
will not sleep anymoreFIX
incorrect doc:debug.getlocal
FIX
completion: incorrect callbackFIX
#592
2021-7-9
FIX
incorrect syntax colorFIX
incorrect type infer
2021-7-8
FIX
change setting may failed
2021-7-8
NEW
detect and apply third-party libraries, including:- OpenResty
- Cocos4.0
- Jass
NEW
LuaDoc
: supports literal table:---@generic T ---@param x T ---@return { x: number, y: T, z?: boolean} local function f(x) end local t = f('str') -- hovering "t" shows: local t: { x: number, y: string, z?: boolean, }
CHG
improve changing config from server sideCHG
improve hover colorCHG
improve performanceCHG
telemetry: sends version of this extensionFIX
supports for file with LFFIX
may infer a custom class as a string
2021-7-2
NEW
supports local config file, using--configpath="config.json"
, learn more hereNEW
gototype definition
NEW
infer type by callback param:---@param callback fun(value: string) local function work(callback) end work(function (value) -- value is string here end)
NEW
optional field---@field name? type
CHG
#549CHG
diagnostics: always ignore the ignored files even if they are openedFIX
completion:type() ==
may does not work
2021-7-1
NEW
hover
andcompletion
reports initialization progressCHG
class field
consider implicit definition---@class Class local mt = {} function mt:init() self.xxx = 1 end function mt:func() print(self.xxx) -- self.xxx is defined end
CHG
improve performanceFIX
#580
2021-6-25
2021-6-24
CHG
improve memory usageFIX
some dialog boxes block the initialization processFIX
diagnosticsundefined-field
: blocks main threadFIX
#565
2021-6-23
NEW
supports literal table inpairs
local t = { a = 1, b = 2, c = 3 } for k, v in pairs(t) do -- `k` is string and `v` is integer here end
CHG
viewlocal f ---@type fun(x:number):boolean
---before function f(x: number) -> boolean ---after local f: fun(x: number): boolean
FIX
#558FIX
#567FIX
#568FIX
#570FIX
#571
2021-6-21
FIX
#566
2021-6-21
NEW
implementCHG
diagnosticsundefined-field
,deprecated
: default byOpened
instead ofNone
CHG
settingLua.runtime.plugin
: default by""
instead of".vscode/lua/plugin.lua"
(for security)CHG
settingLua.intelliSense.searchDepth
: removedCHG
settingLua.misc.parameters
:string array
instead ofstring
CHG
settingLua.develop.enable
,Lua.develop.debuggerPort
,Lua.develop.debuggerWait
: removed, useLua.misc.parameters
insteadFIX
#441FIX
#493FIX
#531FIX
#542FIX
#543FIX
#553FIX
#562FIX
#563
2021-6-17
NEW
supportsuntrusted workspaces
FIX
performance issues, thanks to folke
2021-5-18
2021-5-8
FIX
#529
2021-5-7
NEW
setting:completion.showParams
NEW
LuaDoc
: supports multiline commentsNEW
LuaDoc
: tail comments support lua string
2021-4-30
NEW
setting:completion.autoRequire
NEW
setting:hover.enumsLimit
CHG
folding: supports-- #region
FIX
completion: details may be suspendedFIX
#522FIX
#523
2021-4-13
2021-4-6
2021-4-2
CHG
LuaDoc
: supports---@param self TYPE
CHG
completion: does not show suggests after\n
,{
and,
, unless your settingeditor.acceptSuggestionOnEnter
isoff
FIX
#482
2021-3-27
FIX
telemetry window blocks initializingFIX
#468
2021-3-27
CHG
telemetry: change to opt-in, see #462 and Privacy-PolicyFIX
#467
2021-3-22
2021-3-18
NEW
VSCode: new settingLua.misc.parameters
NEW
new settingLua.runtime.builtin
, used to disable some built-in librariesNEW
quick fix: disable diagnostic in line/fileNEW
setting:Lua.runtime.path
supports absolute pathNEW
completion: field in table
---@class A
---@field x number
---@field y number
---@field z number
---@type A
local t = {
-- provide `x`, `y` and `z` here
}
NEW
LuaDoc
: supports multi-line comment before resume
---this is
---a multi line
---comment
---@alias XXXX
---comment 1
---comment 1
---| '1'
---comment 2
---comment 2
---| '2'
---@param x XXXX
local function f(x)
end
f( -- view comments of `1` and `2` in completion
CHG
intelli-scense: search from generic param to returnCHG
intelli-scense: search across varargCHG
text-document-synchronization: refactoredCHG
diagnostic: improvenewline-call
CHG
completion: improvethen .. end
CHG
improve initialization speedCHG
improve performanceFIX
missed syntax errorfunction m['x']() end
FIX
#452
2021-3-10
CHG
semantic-tokens: improve colors ofconst
andclose
CHG
type-formating: improve execution conditionsFIX
#444
2021-3-9
NEW
LuaDoc
: supports---@diagnostic disable
NEW
code-action: convert JSON to LuaNEW
completion: providethen .. end
snippetNEW
type-formating:-- press `enter` at $ local function f() $ end -- formating result: local function f() $ end -- as well as do $ end -- formating result do $ end
CHG
Windows
: dose not provideucrt
any moreCHG
Lua.workspace.library
: usepath[]
instead of<path, true>
FIX
missed syntax errorlocal a <const>= 1
FIX
workspace: preload blocked when hittingLua.workspace.maxPreload
FIX
#443FIX
#445
2021-3-4
2021-3-3
CHG
intelli-scense: treatV[]
astable<integer, V>
inpairs
FIX
completion:detail
disappears during continuous inputFIX
#435FIX
#436FIX
#437
2021-3-2
FIX
running in Windows
2021-3-1
CHG
intelli-scense: improve infer acrosstable<K, V>
andV[]
.CHG
intelli-scense: improve infer acrosspairs
andipairs
FIX
hover: shows nothing when hovering unknown functionFIX
#398FIX
#421FIX
#422
2021-2-24
NEW
diagnostic:duplicate-set-field
NEW
diagnostic:no-implicit-any
, disabled by defaultCHG
completion: improve field and tableCHG
improve infer crossipairs
CHG
cache globals when loadingCHG
completion: remove trigger character\n
for now, see #401FIX
diagnositc: may open file with wrong uri caseFIX
#406
2021-2-22
FIX
signature: parameters may be misplacedFIX
completion: interface in nested tableFIX
completion: interface not show after,
FIX
#400FIX
#402FIX
#403FIX
#404FIX
runtime errors
2021-2-20
NEW
file encoding supportsansi
NEW
completion: supports interface, see #384NEW
LuaDoc
: supports multiple class inheritance:---@class Food: Burger, Pizza, Pie, Pasta
CHG
renametable*
totablelib
CHG
LuaDoc
: revert compatible with--@
, see #392CHG
improve performanceFIX
missed syntax errorf() = 1
FIX
missed globalbit
inLuaJIT
FIX
completion: may insert error text when continuous inputingFIX
completion: may insert error text after resolveFIX
#349FIX
#396
2021-2-18
CHG
diagnostic:unused-local
excludesdoc.param
CHG
definition: excludes values, see #391FIX
not works on Linux and macOS
2021-2-9
NEW
LUNAR YEAR, BE HAPPY!CHG
diagnostic: when there are too many errors, the main errors will be displayed firstCHG
main thread no longer loop sleeps, see #329 #386CHG
improve performance
2021-2-8
2021-2-4
2021-2-2
FIX
#372
2021-2-2
NEW
VSCode
hintNEW
flush cache after 5 minNEW
VSCode
help semantic color with market themeCHG
create/delete/rename files no longer reload workspaceCHG
LuaDoc
: compatible with--@
FIX
VSCode
settingsFIX
#368FIX
#371
2021-1-28
NEW
VSCode
status barNEW
VSCode
options in some windowCHG
performance optimizationFIX
endless loop
2021-1-27
CHG
performance optimizationFIX
modifying the code before loading finish makes confusionFIX
signature: not works
2021-1-27
FIX
endless loop
2021-1-26
2021-1-7
2021-1-5
CHG
performance optimization
2021-1-5
NEW
Lua.runtime.plugin
NEW
intelli-scense: improvedm.f = function (self) end
fromself
tom
CHG
performance optimizationCHG
completion: improve performance of workspace wordsFIX
hover: tail comments may be cuttedFIX
runtime errors
2021-1-4
NEW
workspace: supports.dll
(.so
) inrequire
NEW
folding:---@class
,--#region
and docs of functionNEW
diagnostic:count-down-loop
CHG
supports~
in command lineCHG
completion: improve workspace wordsCHG
completion: show words in stringCHG
completion: splitfor .. in
tofor .. ipairs
andfor ..pairs
CHG
diagnostic:unused-function
checks recursiveFIX
#339
2020-12-31
NEW
YEAR! Peace and love!NEW
specify path oflog
andmeta
by--logpath=xxx
and--metapath=XXX
in command lineNEW
completion: worksapce wordNEW
completion: show words in commentNEW
completion: generate function documentationCHG
got arg after script name:lua-language-server.exe main.lua --logpath=D:\log --metapath=D:\meta --develop=false
FIX
runtime errors
2020-12-29
CHG
performance optimization
2020-12-24
FIX
telemetry: connect failed caused not working
2020-12-23
NEW
runtime: support nonstandard symbolNEW
diagnostic:close-non-object
FIX
#318
2020-12-20
FIX
workspace: preload may failed
2020-12-20
FIX
luadoc: typo ofpackage.config
FIX
#310
2020-12-17
CHG
completion: use custom tabsizeFIX
#307FIX
a lot of runtime errors
2020-12-16
NEW
setting:diagnostics.neededFileStatus
FIX
scan workspace may failsFIX
quickfix:newline-call
failedFIX
a lot of other runtime errors
2020-12-16
NEW
diagnostic:undefined-field
NEW
telemetry:CHG
diagnostic:unused-function
ignores function with<close>
CHG
semantic: not cover local callCHG
language client: update to 7.0.0FIX
semantic: tokens may not be updated correctlyFIX
completion: require path brokenFIX
hover: document uriFIX
#291FIX
#294
2020-12-14
NEW
completion: auto require local modulesNEW
completion: support delegateNEW
hover: show function by keywordfunction
NEW
code action: swap paramsCHG
standalone: unbind the relative path between binaries and scriptsCHG
hover:LuaDoc
also catchs--
(no need---
)CHG
rename: support docCHG
completion: keyword considers expressionFIX
#297
2020-12-5
NEW
settingruntime.unicodeName
NEW
fully supports---@generic T
FIX
#274FIX
#276FIX
#279FIX
#280
2020-12-3
NEW
settinghover.previewFields
: limit how many fields are shown in table hoverNEW
fully supports---@type Object[]
NEW
supports---@see
NEW
diagnosticunbalanced-assignments
CHG
resolves infer ofstring|table
CHG
unused-local
ignores local with---@class
CHG
locale file format changes tolua
2020-12-1
NEW
provides change logs, I think it's good idea for people knowing what's new(bugs)NEW
meta files of LuaJITNEW
support completion oftype(o) == ?
CHG
now I think it's a bad idea as it took me nearly an hour to complete the logs started from version1.0.0
FIX
closing ignored or library file dose not clean diagnosticsFIX
searching oft.f1
whent.f1 = t.f2
FIX
missing signature help of global function
2020-11-27
FIX
syntaxes tokens: #272
2020-11-27
NEW
hover shows comments from---@param
and---@return
: #135NEW
supportLuaDoc
as tail commentFIX
---@class
inheritanceFIX
missed syntaxes token:punctuation.definition.parameters.finish.lua
2020-11-25
FIX
wiered completion suggests for require paths inLinux
andmacOS
: #269
2020-11-25
FIX
extension not works inUbuntu
: #268
2020-11-24
NEW
auto completion finds globals fromLua.diagnostics.globals
NEW
support tailLuaDoc
CHG
no moreLua.intelliScense.fastGlobal
, now globals always fast and accurateCHG
LuaDoc
supports--- @
CHG
find reference
uses extraLua.intelliSense.searchDepth
CHG
diagnostics are limited by100
in each fileFIX
library files are under limit ofLua.workspace.maxPreload
: #266
2020-11-23
NEW
auto completion special marks deprecated itemsFIX
diagnostics may push wrong uri inLinux
andmacOS
FIX
diagnostics not cleaned up when closing ignored lua fileFIX
reload workspace remains old cachesFIX
incorrect hover of local attribute
2020-11-20
NEW
no longerBETA
NEW
usemeta.lua
instead ofmeta.lni
, now you can find the definition of builtin functionCHG
Lua files outside of workspace no longer launch a new server
2020-11-20
NEW
diagnosticcode-after-break
CHG
optimize performanceCHG
updated language clientCHG
unused-function
ignores global functions (may used out of Lua)CHG
checks if client supportsLua.completion.enable
: #259FIX
support for single Lua fileFIX
#257
2020-11-14
NEW
LuaDoc
supports moreEmmyLua
2020-11-12
FIX
extension not works
2020-11-12
NEW
server kills itself when disconnectingNEW
LuaDoc
supports moreEmmyLua
FIX
Lua.diagnostics.enable
not works: #251
2020-11-11
NEW
supports---|
afterdoc.type
CHG
lowcase-global
ignores globals with---@class
FIX
endless loopFIX
#244
2020-11-10
FIX
autocompletion not works.
2020-11-9
NEW
implementation, NEW start!