diff options
author | 最萌小汐 <sumneko@hotmail.com> | 2019-11-22 23:26:32 +0800 |
---|---|---|
committer | 最萌小汐 <sumneko@hotmail.com> | 2019-11-22 23:26:32 +0800 |
commit | d0ff66c9abe9d6abbca12fd811e0c3cb69c1033a (patch) | |
tree | bb34518d70b85de7656dbdbe958dfa221a3ff3b3 /server-beta/src/core/hover/table.lua | |
parent | 0a2c2ad15e1ec359171fb0dd4c72e57c5b66e9ba (diff) | |
download | lua-language-server-d0ff66c9abe9d6abbca12fd811e0c3cb69c1033a.zip |
整理一下目录结构
Diffstat (limited to 'server-beta/src/core/hover/table.lua')
-rw-r--r-- | server-beta/src/core/hover/table.lua | 35 |
1 files changed, 0 insertions, 35 deletions
diff --git a/server-beta/src/core/hover/table.lua b/server-beta/src/core/hover/table.lua deleted file mode 100644 index 9ed86692..00000000 --- a/server-beta/src/core/hover/table.lua +++ /dev/null @@ -1,35 +0,0 @@ -local vm = require 'vm' - -local function checkClass(source) -end - -return function (source) - local fields = {} - local class - vm.eachField(source, function (info) - if info.key == 's|type' or info.key == 's|__name' or info.key == 's|name' then - if info.value and info.value.type == 'string' then - class = info.value[1] - end - end - local type = vm.getType(info.source) - fields[#fields+1] = ('%s'):format(type) - end) - local fieldsBuf - if #fields == 0 then - fieldsBuf = '{}' - else - local lines = {} - lines[#lines+1] = '{' - for _, field in ipairs(fields) do - lines[#lines+1] = ' ' .. field - end - lines[#lines+1] = '}' - fieldsBuf = table.concat(lines, '\n') - end - if class then - return ('%s %s'):format(class, fieldsBuf) - else - return fieldsBuf - end -end |