diff options
author | 最萌小汐 <sumneko@hotmail.com> | 2023-08-14 18:01:58 +0800 |
---|---|---|
committer | 最萌小汐 <sumneko@hotmail.com> | 2023-08-14 18:01:58 +0800 |
commit | f09aa4104a56996e838dd30d28bbef706e461469 (patch) | |
tree | 47af5ff871d0cb28a4e563a4ad7ba16980eedea1 /script/vm/compiler.lua | |
parent | 5ccedb1cf07a73a8e0eb4ace84b320c8a997dbbb (diff) | |
download | lua-language-server-f09aa4104a56996e838dd30d28bbef706e461469.zip |
fix warning
Diffstat (limited to 'script/vm/compiler.lua')
-rw-r--r-- | script/vm/compiler.lua | 15 |
1 files changed, 10 insertions, 5 deletions
diff --git a/script/vm/compiler.lua b/script/vm/compiler.lua index f07bcdc6..7e026474 100644 --- a/script/vm/compiler.lua +++ b/script/vm/compiler.lua @@ -7,11 +7,14 @@ local files = require 'files' local vm = require 'vm.vm' ---@class parser.object ----@field _compiledNodes boolean ----@field _node vm.node ----@field cindex integer ----@field func parser.object ----@field hideView boolean +---@field _compiledNodes boolean +---@field _node vm.node +---@field cindex integer +---@field func parser.object +---@field hideView boolean +---@field package _returns? parser.object[] +---@field package _callReturns? parser.object[] +---@field package _asCache? parser.object[] -- 该函数有副作用,会给source绑定node! ---@param source parser.object @@ -483,6 +486,7 @@ function vm.getReturnOfFunction(func, index) func._returns = {} end if not func._returns[index] then + ---@diagnostic disable-next-line: missing-fields func._returns[index] = { type = 'function.return', parent = func, @@ -580,6 +584,7 @@ local function getReturn(func, index, args) end if not func._callReturns[index] then local call = func.parent + ---@diagnostic disable-next-line: missing-fields func._callReturns[index] = { type = 'call.return', parent = call, |